Skip to content

fygarcia/AgentOS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Omni-Finn: AgentOS + Agent Finn

A domain-agnostic agentic operating system with a financial specialist
Status: Phase 1 - Foundation COMPLETE (MVP 1.0) Last Updated: 2026-02-01


For New Developers/LLMs: BEFORE RUNNING ANYTHING REMEMBER TO ACTIVATE VENV

  1. Start with README.md (this file)
  2. Read docs/ROADMAP.md (what we're building)
  3. Read docs/STATUS.md (current state)
  4. Read docs/AGENTOS_SPEC.md (how to build)
  5. Read docs/STRUCTURE.md (where things are)

🎯 What is This?

Omni-Finn is a two-layer autonomous system:

  1. AgentOS - A reusable agentic framework (the "operating system")

    • Provides orchestration, skill management, persistent memory
    • Domain-agnostic - can power any type of agent
    • Built on LangGraph + Local Ollama LLMs
    • NEW: Three-tier memory system (HOT/WARM/COLD) with LanceDB
  2. Agent Finn - A financial portfolio manager (the "application")

    • Autonomous data ingestion from bank statements
    • Zero-error financial calculations (decimal precision)
    • Proactive research and delta reports

Current Focus: Building AgentOS first, then integrating Finn


πŸ—οΈ Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Agent Finn (Financial Specialist)                          β”‚
β”‚  β€’ Portfolio management                                     β”‚
β”‚  β€’ Data ingestion & reconciliation                          β”‚
β”‚  β€’ Research & analysis                                      β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                          ↓
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  AgentOS (Domain-Agnostic Framework)                        β”‚
β”‚  β€’ Classifier Node (Task vs Question Routing) [NEW]         β”‚
β”‚  β€’ Planner β†’ Actor β†’ Auditor workflow                       β”‚
β”‚  β€’ Enhanced Auditor with Verification Strategies [NEW]      β”‚
β”‚  β€’ Skill registry & execution                               β”‚
β”‚  β€’ Persistent memory (NOW.md + LOG.md + SQLite + LanceDB)   β”‚
β”‚  β€’ Self-healing loops (Phase 2)                             β”‚
β”‚  β€’ Multi-agent orchestration (Phase 2)                      β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                          ↓
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Infrastructure                                             β”‚
β”‚  β€’ Local Ollama LLMs (RTX 4090)                             β”‚
β”‚  β€’ LangGraph for state management                           β”‚
β”‚  β€’ SQLite for structured memory & facts                     β”‚
β”‚  β€’ LanceDB for semantic search (Cold Memory)                β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

πŸš€ Quick Start

Prerequisites

# Required
- Python 3.10+ (3.14 supported)
- Ollama running locally
- Models: gpt-oss:20b, llama3.1:8b

# Check Ollama is running
curl http://192.168.4.102:11434/api/tags

Installation

# Clone and setup
git clone <repo-url>
cd Agent-FIN

# Create virtual environment
python -m venv venv
# Windows
.\venv\Scripts\Activate.ps1
# Linux/Mac
source venv/bin/activate

# Install dependencies
pip install -r requirements.txt

# Verify installation
python -c "import pydantic, yaml; print('βœ… Dependencies OK')"

# Configure environment
cp .env.example .env
# Edit .env with your Ollama URL and model names

Configuration

Create .env file:

# LLM Provider
LLM_PROVIDER=ollama
OLLAMA_BASE_URL=http://192.168.4.102:11434

# Models
REASONING_MODEL=gpt-oss:20b
PARSER_MODEL=llama3.1:8b
TOOL_MODEL=llama3.1:8b

# Observability
ENABLE_OBSERVABILITY=true

Run Tests

# Quick tests (mock provider)
python tests/test_auditor.py
python tests/test_graph_routing.py
python tests/test_actor.py

# Integration tests (requires Ollama)
python tests/test_planner_pydantic.py
python tests/test_agent_integration.py

Run AgentOS

# Run a simple workflow
python core/engine.py "Create a file named hello.txt with content 'AgentOS is working'"

# OR via Agent class (Recommended)
# See scripts or interactive shell

πŸ“ Project Structure

/Agent-FIN
β”œβ”€β”€ /core                   # AgentOS - Domain-Agnostic Framework
β”‚   β”œβ”€β”€ engine.py           # Main entry point
β”‚   β”œβ”€β”€ agent.py            # Agent class definition
β”‚   β”œβ”€β”€ graph.py            # LangGraph workflow definition
β”‚   β”œβ”€β”€ state.py            # AgentState schema
β”‚   β”œβ”€β”€ models.py           # Pydantic models (Plan, PlanStep, etc.)
β”‚   β”œβ”€β”€ memory_manager.py   # Persistent memory system (LanceDB)
β”‚   β”œβ”€β”€ memory_schema.sql   # Memory database schema
β”‚   β”œβ”€β”€ llm.py              # LLM provider interface
β”‚   β”œβ”€β”€ two_stage_client.py # Reasoning + parsing pipeline
β”‚   β”œβ”€β”€ observability.py    # Tracing & monitoring
β”‚   β”œβ”€β”€ /nodes              # Execution nodes
β”‚   β”‚   β”œβ”€β”€ planner.py      # Intent β†’ Plan
β”‚   β”‚   β”œβ”€β”€ actor.py        # Plan β†’ Execution
β”‚   β”‚   └── auditor.py      # Execution β†’ Verification
β”‚   └── /skills/memory      # Native memory skills
β”‚
β”œβ”€β”€ /docs                   # πŸ“š All Documentation
β”‚   β”œβ”€β”€ ROADMAP.md          # Development roadmap
β”‚   β”œβ”€β”€ STATUS.md           # Current status
β”‚   β”œβ”€β”€ AGENTOS_SPEC.md     # Technical specification
β”‚   β”œβ”€β”€ STRUCTURE.md        # File organization
β”‚   β”œβ”€β”€ MEMORY_SYSTEM.md    # Memory architecture
β”‚   β”œβ”€β”€ AGENT_STRUCTURE_STANDARD.md # Agent directory standard
β”‚   └── /legacy             # Archived documentation
β”‚
β”œβ”€β”€ /finn                   # Agent Finn - Financial Specialist
β”‚   β”œβ”€β”€ /config             # Agent configuration & SOPs
β”‚   β”œβ”€β”€ /skills             # Finn-specific skills
β”‚   β”œβ”€β”€ /directives         # SOPs & procedures
β”‚   β”œβ”€β”€ /memory             # Agent memory (NOW.md, LOG.md, memory.db)
β”‚   └── /inbox              # Watch folder for ingestion
β”‚
β”œβ”€β”€ /tests                  # Test suite
β”‚   β”œβ”€β”€ README.md           # Test documentation
β”‚   β”œβ”€β”€ test_*.py           # Test files
β”‚   └── /results            # Test outputs & artifacts
β”‚
β”œβ”€β”€ README.md               # This file - start here
β”œβ”€β”€ requirements.txt        # Python dependencies
└── .env                    # Environment configuration

πŸ“š Documentation

🌟 Start Here:

  1. docs/ROADMAP.md - Development plan, priorities, milestones
  2. docs/STATUS.md - Current state, progress, known issues
  3. docs/AGENTOS_SPEC.md - Technical specification

Detailed Docs:


🎯 Current Status

βœ… What's Working

  • βœ… Intent Classification (Smart Routing)
    • Distinguishes between Tasks ("Create file") and Questions ("What is X?")
    • Routes Questions to fast-path Responder node
    • Routes Tasks to full Planner loop
  • βœ… Enhanced Auditor (Reliable Verification)
    • Verifies actual side-effects (file creation, content presence)
    • Uses strategy pattern (verify_file_exists, verify_content, etc.)
  • βœ… Planner β†’ Actor β†’ Auditor workflow
  • βœ… Agent-Engine Integration (Agent class drives workflow)
  • βœ… Two-stage reasoning (gpt-oss:20b + llama3.1:8b)
  • βœ… LangGraph state management
  • βœ… Persistent Memory System (HOT/WARM/COLD architecture)
    • NOW.md for current status
    • LOG.md for activity history
    • SQLite for user facts & metadata
    • LanceDB for semantic search (Cold Memory)
    • Auto-logging & context injection
    • Self-annealing error recovery
  • βœ… Skill registry system with metadata discovery
  • βœ… Memory skills (update_status, log_activity, save_fact, etc.)
  • βœ… Test suite (All passing)

πŸ”„ In Progress

  • πŸ”„ Phase 2: Self-Healing Loops

❌ Not Yet Implemented

  • ❌ Multi-agent support (Phase 2)
  • ❌ Agent Finn integration (Phase 3)

See docs/STATUS.md for detailed progress


🚦 Development Phases

Phase 1: AgentOS Foundation (COMPLETE - 100%)

Goal: Build tested, reusable agentic core

  • 1A: Core workflow βœ… 100%
  • 1B: Skill Registry & Integration βœ… 100%
  • 1C: Intent Classification βœ… 100% (Smart Routing)
  • 1D: Enhanced auditor βœ… 100% (Strategy Verification)
  • 1E: Persistent memory βœ… 100% (LanceDB)

Phase 2: AgentOS Advanced Features (Not Started)

  • Self-healing loops
  • Multi-agent support
  • Advanced workflow patterns

Phase 3: Agent Finn Integration (Not Started)

  • Financial skill catalog
  • Ingestion pipeline
  • Sub-agents (Accountant, OCR, Researcher)

Phase 4: Production Deployment (Future)

  • Observability & monitoring
  • Performance optimization
  • User interface

See docs/ROADMAP.md for detailed breakdown


πŸ§ͺ Testing

# Run all quick tests (<5 seconds)
python tests/test_auditor.py && \
python tests/test_graph_routing.py && \
python tests/test_actor.py

# Run integration tests (requires Ollama, ~30 seconds)
python tests/test_planner_pydantic.py
python tests/test_agent_integration.py

# Run full E2E test (requires Ollama, ~2-3 minutes)
python tests/test_e2e_workflow.py

Test Coverage: ~85%

  • Unit tests: Passing
  • Integration tests: Passing
  • End-to-end tests: Passing

See tests/README.md for detailed test documentation


πŸ”§ Tech Stack

Component Technology Purpose
Orchestration LangGraph State management & workflow routing
LLM Server Ollama Local LLM inference
Reasoning Model gpt-oss:20b Planning & high-level reasoning
Tool Model llama3.1:8b Code generation & structured output
Validation Pydantic V2 Type-safe data models
Database SQLite Portfolio data + memory storage
Vector DB LanceDB Semantic memory (cold tier)
Observability LangSmith Tracing & debugging

🀝 Contributing

Development Workflow

  1. Read the docs

  2. Pick a task

    • See docs/ROADMAP.md for current sprint
    • Check GitHub issues (if available)
  3. Write tests first

    • Follow existing test patterns in /tests
    • See tests/README.md for guidelines
  4. Submit PR (if applicable)

    • Include tests
    • Update documentation
    • Follow Pydantic V2 patterns

πŸ“ Key Design Principles

1. Separation of Concerns

  • AgentOS = Domain-agnostic infrastructure
  • Agents = Domain-specific knowledge & skills
  • Never mix domain logic into core

2. Skill-Oriented Architecture

  • All capabilities as discoverable skills
  • Metadata-driven skill registry
  • Dynamic skill loading & execution

3. Model Flexibility

  • All models configurable via environment
  • Support for local & cloud LLMs
  • Graceful degradation

4. Test-Driven Development

  • 80% code coverage target

  • Tests for every component
  • Mock for speed, Ollama for integration

5. Observability First

  • Trace every LLM call
  • Log all state transitions
  • Debug-friendly error messages

πŸ› Known Issues

  1. Auditor Loop - Failed verification doesn't yet trigger automatic retry/healing (Phase 2)
  2. Context Window - Very long conversation histories may hit context limits (Need to implement summary rollover)

See docs/STATUS.md for full list


πŸ”— Links & Resources


πŸ“„ License

[To be determined]


πŸ‘₯ Team

  • Development: [Your Name]
  • Architecture: AI-Assisted Design
  • Infrastructure: RTX 4090 Homelab

πŸ“ž Support

For questions about:


Last Updated: 2026-02-01
Version: 1.0 (MVP - Phase 1 Complete)
Next Milestone: Self-Healing Loops (Phase 2)

About

versatile agent with core features for new specialized agents

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages