Skip to main content

A self-improving code reasoning engine with persistent semantic memory

Project description

Neo Banner: Imagery from The Matrix film series


Neo

A self-improving code reasoning engine that learns from experience using persistent semantic memory. Neo uses multi-agent reasoning to analyze code, generate solutions, and continuously improve through feedback loops.

  • Fact-Based Memory: Learns from every solution attempt using a scoped, supersession-based fact store
  • Semantic Retrieval: Vector search finds relevant facts via Jina Code embeddings
  • Code-First Generation: No diff parsing failures
  • Local Storage: Privacy-first JSON storage in ~/.neo/facts/ directory
  • Model-Agnostic: Works with any LM provider
  • Available as a Claude Code Plugin: Integrates seamlessly with Anthropic's Claude models and CLI.

Claude Code Plugin Banner: Background is an illustration of a terminal or console.

PyPI version Python Versions License: Apache 2.0

Why Neo? Why Care?

If you've been Vibe Coding, then Vibe Planning, then Context Engineering, and on and on, you have likely hit walls where the models are both powerful and limited, brilliant and incompetent, wise and ignorant, humble yet overconfident.

Worse, your speedy AI Code Assistant sometimes goes rogue and overwrites key code in a project, or writes redundant code even after just reading documentation and the source code, or violates your project's patterns and design philosophy.... It can be infuriating. Why doesn't the model remember? Why doesn't it learn? Why can't it keep the context of the code patterns and tech stack? ... -> This is what Neo is designed to solve.

Neo is the missing context layer for AI Code Assistants. It learns from every solution attempt, using vector embeddings to retrieve relevant patterns for new problems. It then applies the learned patterns to generate solutions, and continuously improves through feedback loops.

Table of Contents

Design Philosophy

Fact-Based Learning: Neo builds a semantic memory of facts — constraints, architectural decisions, patterns, review learnings, decisions, known unknowns, and failures — using vector embeddings for retrieval.

Code-First Output: Instead of generating diffs that need parsing, Neo outputs executable code blocks directly, eliminating extraction failures.

Scoped Storage: Facts are scoped to global, organization, or project level, stored locally in ~/.neo/facts/ for privacy and offline access.

Model-Agnostic: Works with OpenAI, Anthropic, Google, local models, or Ollama via a simple adapter interface.

How It Works

User Problem → Neo CLI → Semantic Retrieval → Reasoning → Code Generation
                           ↓
                    [Vector Search]
                    [Pattern Matching]
                    [Confidence Scoring]
                           ↓
                    Executable Code + Memory Update

Neo retrieves relevant facts using Jina Code embeddings (768-dimensional vectors), applies learned patterns, generates solutions, and stores new facts for continuous improvement.

  1. Jina's embeddings model (open source) is downloaded automatically when you first run Neo. This model runs locally on your machine to generate vector embeddings.

The Construct

Neo includes The Construct - a curated library of architecture and design patterns with semantic search capabilities. Think of it as your personal reference library for common engineering patterns, indexed and searchable using the same embedding technology that powers Neo's reasoning memory.

What is The Construct?

The Construct is a collection of vendor-agnostic design patterns covering:

  • Rate Limiting: Token bucket, sliding window, distributed rate limiting
  • Caching: Cache-aside, write-through, invalidation strategies
  • More domains: Additional patterns contributed by the community

Each pattern follows a structured format inspired by the Gang of Four:

  • Intent: What problem does this solve?
  • Forces: Key constraints and tradeoffs
  • Solution: Conceptual structure (no framework-specific code)
  • Consequences: Benefits, risks, and observability signals
  • References: Links to real-world implementations

Using The Construct

# List all patterns
neo construct list

# Filter by domain
neo construct list --domain rate-limiting

# Show a specific pattern
neo construct show rate-limiting/token-bucket

# Semantic search across patterns
neo construct search "how to prevent api abuse"

# Build the search index
neo construct index

Pattern Quality Standards

All patterns must:

  • Include author attribution
  • Be under 300 lines
  • Remain vendor-agnostic (no AWS/GCP/Azure-specific solutions)
  • Include concrete consequences and observability guidance

See /construct/README.md for contribution guidelines.

  1. When you ask Neo for help:
    • Your query is embedded locally using the Jina model
    • Neo searches the fact store for relevant knowledge (using cosine similarity)
    • Retrieved facts are organized into layers: constraints, relevant knowledge, recent changes, known unknowns
    • This combined context is sent to your chosen LLM API (OpenAI/Anthropic/Google)
    • The LLM generates a solution informed by both your query and past facts
    • The result is stored back as a new fact in local memory for future use

Local storage: ~/.neo/facts/facts_global.json ← Global-scoped facts ~/.neo/facts/facts_org_{id}.json ← Organization-scoped facts ~/.neo/facts/facts_project_{id}.json ← Project-scoped facts

Privacy:

  • Your code never leaves your machine during embedding/search
  • Only your prompt + retrieved facts are sent to the LLM API
  • This is the same as using the LLM directly, but with added context from something akin to memory.
  Your Prompt
     ↓
 Local Jina Embedding (768-dim vector)
     ↓
 Cosine Similarity Search (finds relevant facts)
     ↓
 Retrieve Facts from ~/.neo/facts/
     ↓
 Assemble Context: Constraints → Knowledge → Recent Changes → Known Unknowns
     ↓
 →→→ NETWORK CALL →→→ LLM API (OpenAI/Anthropic/etc.)
     ↓
 Solution Generated
     ↓
 Store as New Fact in Local Memory

Quick Start

# Install from PyPI (recommended)
pip install neo-reasoner

# Or install with specific LM provider
pip install neo-reasoner[openai]     # For GPT (recommended)
pip install neo-reasoner[anthropic]  # For Claude
pip install neo-reasoner[google]     # For Gemini
pip install neo-reasoner[all]        # All providers

# Set API key
export OPENAI_API_KEY=sk-...

# Test Neo
neo --version

See QUICKSTART.md for 5-minute setup guide

Claude Code Plugin

Neo is available as a Claude Code plugin with specialized agents and slash commands for seamless integration:

# Add the marketplace
/plugin marketplace add Parslee-ai/claude-code-plugins

# Install Neo plugin
/plugin install neo

Once installed, you get:

  • Neo Agent: Specialized subagent for semantic reasoning (Use the Neo agent to...)
  • Slash Commands: /neo, /neo-review, /neo-optimize, /neo-architect, /neo-debug, /neo-pattern
  • Persistent Memory: Neo learns from your codebase patterns over time
  • Multi-Agent Reasoning: Solver, Critic, and Verifier agents collaborate on solutions

Quick Examples

# Code review with semantic analysis
/neo-review src/api/handlers.py

# Get optimization suggestions
/neo-optimize process_large_dataset function

# Architectural guidance
/neo-architect Should I use microservices or monolith?

# Debug complex issues
/neo-debug Race condition in task processor

See .claude-plugin/README.md for full plugin documentation

Codex Plugin

Neo also ships as a Codex plugin with the same six skills the Claude Code plugin exposes — packaged for OpenAI Codex CLI instead of slash commands.

# Add Neo's local marketplace (works in any clone of this repo)
codex plugin marketplace add Parslee-ai/neo

# Or, from a local checkout, point Codex at the in-tree marketplace:
codex plugin marketplace add ./

Then open Codex's plugin directory and install Neo from the Neo (local) marketplace. Once installed, you get six skills:

  • $neo — semantic reasoning over the current codebase
  • $neo-review — code review with semantic pattern matching
  • $neo-optimize — performance/algorithmic optimization analysis
  • $neo-architect — architectural guidance and design decisions
  • $neo-debug — help debugging intermittent or hard-to-reproduce issues
  • $neo-pattern — extract patterns from code or find pattern instances

Skills wrap the local neo CLI, so you still need the binary installed (pip install neo-reasoner[openai] and OPENAI_API_KEY set). Neo's persistent semantic memory in ~/.neo/ is shared across both plugins — anything you teach Neo from Claude Code is available from Codex too, and vice versa.

See plugins/neo/ for the manifest and skill sources

Works Alongside Your AI Tools

Neo automatically reads project-local agent instruction docs from a wide range of ecosystems and folds them into its reasoning context — no configuration needed. If you've already invested in writing a CLAUDE.md, an AGENTS.md, .cursor/rules/, .github/copilot-instructions.md, or a Spec Kit project, neo respects that work.

Tool Files / dirs neo discovers
Claude / Claude Code CLAUDE.md, .claude/CLAUDE.md, .claude/agents/*.md, .claude/commands/*.md
Codex / AGENTS.md spec AGENTS.md, .github/AGENTS.md, .codex/**/*.md
Cursor .cursorrules, .cursor/rules/**/*.md, .cursor/rules/**/*.mdc
GitHub Copilot .github/copilot-instructions.md
Windsurf .windsurfrules
Continue .continue/**/*.md
Augment .augment/**/*.md
Spec Kit .specify/**/*.md
Aider .aider/*.md
Codeium .codeium/*.md

Discovered docs surface in neo's prompt under PROJECT-LOCAL AGENT CONTEXT, included unconditionally — independent of relevance ranking — because their value is global to the project. Per-file cap of 6KB and total cap of 32KB keep prompt growth bounded.

This means neo composes well with whichever AI coding workflow you already use:

  • Claude Code users get the deepest integration via the Claude Code Plugin, but neo runs standalone too.
  • Codex CLI users get parity via the Codex Plugin — same six skills, packaged for Codex. Neo also automatically picks up AGENTS.md (the cross-tool standard Codex co-led) plus anything under .codex/.
  • Cursor / Windsurf / Aider / Continue / Augment users — the rules dirs you've curated land in every neo session's context.
  • GitHub Copilot users — .github/copilot-instructions.md is read on every invocation.
  • Spec Kit projects — your specs are folded into neo's reasoning context, no manual paste.

Adding a new tool is a one-liner: extend the discovery rules in src/neo/agent_context.py. The list is the load-bearing surface for keeping this current as new agent ecosystems emerge.

Installation

From PyPI (Recommended)

# Install Neo
pip install neo-reasoner

# With specific LM provider
pip install neo-reasoner[openai]     # GPT (recommended)
pip install neo-reasoner[anthropic]  # Claude
pip install neo-reasoner[google]     # Gemini
pip install neo-reasoner[all]        # All providers

# Verify installation
neo --version

Updating Neo

Neo supports both manual and fully automatic updates:

Manual Updates

# Option 1: Use neo's built-in update command (simplest)
neo update

# Option 2: Update with pip
pip install --upgrade neo-reasoner

# Option 3: Use pipx for isolated installation (recommended for end users)
pipx install neo-reasoner          # First-time install
pipx upgrade neo-reasoner           # Update to latest version
pipx upgrade-all                    # Update all pipx packages

Fully Automatic Updates

Enable automatic installation of updates in the background:

# Enable auto-install (persisted in ~/.neo/config.json)
neo --config set --config-key auto_install_updates --config-value true

# Or use environment variable
export NEO_AUTO_INSTALL_UPDATES=1

When enabled, Neo will:

  • Check for updates once every 24 hours
  • Automatically download and install new versions in the background
  • Notify you when updates complete
  • Log all auto-update activity to ~/.neo/auto_update.log

Example output when auto-install is enabled:

$ neo "your query" Auto-installing neo update: 0.9.0  0.10.0
   This happens in the background. Please wait...

✓ Auto-update completed: 0.10.0
   Restart neo to use the new version.

[Neo] Processing your query...

Update Notifications (Default)

By default, Neo checks for updates once every 24 hours and displays a notification when a new version is available. This check happens in the background and will not interrupt your workflow.

To disable update checks entirely:

export NEO_SKIP_UPDATE_CHECK=1

From Source (Development)

# Clone repository
git clone https://github.com/Parslee-ai/neo.git
cd neo

# Install in development mode with all dependencies
pip install -e ".[dev,all]"

# Verify installation
neo --version

Dependencies

Core dependencies are automatically installed via pyproject.toml:

  • numpy >= 1.24.0
  • scikit-learn >= 1.3.0
  • datasketch >= 1.6.0
  • fastembed >= 0.3.0
  • faiss-cpu >= 1.7.0
  • jsonschema >= 4.0.0

Optional: LM Provider

Choose your language model provider:

pip install openai                  # GPT models (recommended)
pip install anthropic               # Claude
pip install google-genai>=0.2.0     # Gemini (requires Python 3.10+)
pip install requests                # Ollama

See INSTALL.md for detailed installation instructions

Usage

CLI Interface

# Ask Neo a question
neo "how do I fix the authentication bug?"

# With working directory context
neo --cwd /path/to/project "optimize this function"

# Check version and memory stats
neo --version

Timeout Requirements

Neo makes blocking LLM API calls that typically take 30-120 seconds. When calling Neo from scripts or automation, use appropriate timeouts:

# From shell (10 minute timeout)
timeout 600 neo "your query"

# From Python subprocess
subprocess.run(["neo", query], timeout=600)

Insufficient timeouts will cause failures during LLM inference, not context gathering.

Output Format

Neo outputs executable code blocks with confidence scores:

def solution():
    # Neo's generated code
    pass

Personality System

Neo responds with personality (Matrix-inspired quotes) when displaying version info:

$ neo --version
"What is real? How do you define 'real'?"

neo 0.9.0
Provider: openai | Model: gpt-5.5
Stage: Sleeper | Memory: 0.0%
░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░
0 facts | 0.00 avg confidence

Load Program - Training Neo's Memory

"The Operator uploads a program into Neo's head."

Neo can bootstrap its memory by importing facts from HuggingFace datasets. This is NOT model fine-tuning - it's retrieval learning that expands local semantic memory with reusable code knowledge.

# Install datasets library
pip install datasets

# Load patterns from MBPP (recommended starter - 1000 Python problems)
neo --load-program mbpp --split train --limit 1000

# Load from OpenAI HumanEval (164 hand-written coding problems)
neo --load-program openai_humaneval --split test

# Load from BigCode HumanEvalPack (multi-language variants)
neo --load-program bigcode/humanevalpack --split test --limit 500

# Dry run to preview
neo --load-program mbpp --dry-run

# Custom column mapping
neo --load-program my_dataset \
    --columns '{"text":"pattern","code":"solution"}'

Output (Matrix-style):

"I know kung fu."

Loaded: 847 facts
Deduped: 153 duplicates
Index rebuilt: 1.2s
Memory: 1247 total facts

How it works:

  1. Acquire: Pull dataset from HuggingFace
  2. Normalize: Map rows to fact schema
  3. Dedupe: Hash-based deduplication against existing memory
  4. Embed: Generate local embeddings (Jina Code v2)
  5. Store: Add as facts to the fact store
  6. Report: Matrix quote + counts

Key points:

  • NOT fine-tuning - just expanding retrieval memory
  • Facts start at 0.3 confidence (trainable via real-world usage)
  • Automatic deduplication prevents memory bloat
  • Uses local embeddings (no data leaves your machine)
  • Stored in ~/.neo/facts/ alongside learned facts

See docs/LOAD_PROGRAM.md for detailed documentation

Architecture

Fact-Based Memory

Neo uses a scoped, supersession-based fact store with Jina Code v2 embeddings (768 dimensions) for semantic retrieval:

  1. Fact Storage: Knowledge is stored as typed facts (constraints, architecture, patterns, review learnings, decisions, known unknowns, failures)
  2. Scoped Organization: Facts are scoped to global, organization, or project level — automatically detected from git remotes
  3. Supersession: When a new fact closely matches an existing one (cosine similarity > 0.85), the old fact is superseded rather than duplicated
  4. Confidence Scoring: Facts carry confidence scores with automatic boosting on supersession
  5. Four-Layer Context: Retrieved facts are organized into constraints, relevant knowledge, recent changes, and known unknowns (inspired by StateBench)
  6. Local Persistence: Facts stored locally in JSON format in ~/.neo/facts/

Output Schemas

Neo generates structured outputs with executable code and planning artifacts:

CodeSuggestion - Executable code with actionable metadata:

@dataclass
class CodeSuggestion:
    # Core fields
    file_path: str
    unified_diff: str           # Legacy: backward compatibility
    code_block: str = ""        # Primary: executable Python code
    description: str
    confidence: float
    tradeoffs: list[str]

    # Executable artifacts (v0.8.0+)
    patch_content: str = ""            # Full unified diff content
    apply_command: str = ""            # Shell command to apply (advisory)
    rollback_command: str = ""         # Shell command to undo (advisory)
    test_command: str = ""             # Shell command to verify (advisory)
    dependencies: list[str] = []       # Other suggestion IDs this depends on
    estimated_risk: str = ""           # "low", "medium", or "high"
    blast_radius: float = 0.0          # 0.0-100.0 percentage of codebase affected

PlanStep - Incremental planning with step-level metadata:

@dataclass
class PlanStep:
    # Core fields
    description: str
    rationale: str
    dependencies: list[int] = []

    # Incremental planning (v0.8.0+)
    preconditions: list[str] = []      # Conditions before execution
    actions: list[str] = []            # Concrete actions to perform
    exit_criteria: list[str] = []      # Success verification criteria
    risk: str = "low"                  # "low", "medium", "high"
    retrieval_keys: list[str] = []     # Step-scoped memory retrieval
    failure_signatures: list[str] = [] # Known failure patterns
    verifier_checks: list[str] = []    # Validation checks (Solver-Critic-Verifier)
    expanded: bool = False             # Tracks seed → expansion

These schemas enable:

  • Actionable Output: Commands and patches ready for execution
  • Incremental Planning: Seed plans expand only when blocked (as-needed decomposition)
  • Step-Level Learning: Failure signatures attach to specific steps for ReasoningBank
  • Multi-Agent Reasoning: Verifier checks support MapCoder's Solver-Critic-Verifier pattern

Code Smell Detection in Context Assembly

Neo scans the relevance-ranked file set during context assembly and surfaces known issues to the model under KNOWN ISSUES IN NEARBY CODE. Detectors are intentionally high-precision (false positives turn into prompt bloat that hurts more than it helps):

  • TODO / FIXME / HACK / XXX markers (any text file)
  • Python stubs: pass-only / ...-only / raise NotImplementedError
  • Python bare except: and swallowed exceptions (except ...: pass)
  • Hardcoded credentials matching well-known prefixed shapes (OpenAI sk-, AWS AKIA, GitHub ghp_, Slack xox*-)

Per-file cap of 8 + global cap of 20 findings keeps the prompt bounded. Magic numbers and generic high-entropy secret detection are intentionally out of scope — they'd add more noise than signal at this stage.

Storage Architecture

  • Scoped JSON Files: Facts stored in ~/.neo/facts/ — separate files per scope (global, org, project)
  • Inline Embeddings: Vector embeddings stored alongside facts in JSON (no separate FAISS index for memory)
  • Supersession: Similar facts are superseded rather than merged — old facts remain but are marked invalid
  • Constraint Auto-Ingestion: CLAUDE.md and similar files are automatically scanned and ingested as CONSTRAINT facts
  • Project Index (separate system): Tree-sitter code indexing uses FAISS for per-repository semantic search in .neo/

Performance

Neo improves over time as it learns from experience. Initial performance depends on available facts. Performance grows as the semantic memory builds up successful solutions, failure learnings, and architectural decisions.

Memory-Driven Reasoning Effort (gpt-5* models)

Neo monetizes its learning into inference cost. Each query's reasoning.effort parameter is sized from the strength of the memory hit:

Memory + difficulty Effort
≥3 patterns, avg confidence ≥ 0.8 low
Some patterns, avg confidence 0.5–0.8 medium (API default)
No relevant patterns OR avg confidence < 0.5 high
No patterns AND difficulty == "hard" xhigh

Familiar queries get cheap thinking; novel-and-hard queries get max thinking. Cap with NEO_REASONING_EFFORT={none,low,medium,high,xhigh} for cost control.

Model note: the effort vocabulary differs by model. gpt-5.5 (the default) accepts the full none / low / medium / high / xhigh range. Older gpt-5-codex only accepts low / medium / high — if you switch back to that model, set NEO_REASONING_EFFORT=high to cap the auto-selector.

Architectural Quality Feedback Loop

When a session ends, neo snapshots three structural metrics — import cycles, god files (LOC + function-count thresholds), and max nesting depth — and diffs against the previous snapshot at the next outcome detection. A regression weakens the accept/boost or strengthens the modify/penalty by 0.1; an improvement does the reverse. Confidence becomes a signal of "helped the codebase," not just "got accepted."

Configuration

CLI Configuration Management

Neo provides a simple CLI for managing persistent configuration:

# List all configuration values
neo --config list

# Get a specific value
neo --config get --config-key provider

# Set a value
neo --config set --config-key provider --config-value anthropic
neo --config set --config-key model --config-value claude-sonnet-4-5-20250929
neo --config set --config-key api_key --config-value sk-ant-...

# Reset to defaults
neo --config reset

Exposed Configuration Fields:

  • provider - LM provider (openai, anthropic, google, azure, ollama, local)
  • model - Model name (e.g., gpt-5.5, claude-sonnet-4-5-20250929)
  • api_key - API key for the chosen provider
  • base_url - Base URL for local/Ollama endpoints
  • memory_backend - Memory backend: "fact_store" (default) or "legacy"
  • auto_install_updates - Automatically install updates in background (true/false)
  • constraint_auto_scan - Auto-scan CLAUDE.md for constraints (true/false, default: true)

Configuration is stored in ~/.neo/config.json and takes precedence over environment variables.

Environment Variables

Alternatively, use environment variables for configuration:

# Required: LM Provider API Key
export ANTHROPIC_API_KEY=sk-ant-...

LM Adapters

OpenAI (Default)

from neo.adapters import OpenAIAdapter
adapter = OpenAIAdapter(model="gpt-5.5", api_key="sk-...")

Default model: gpt-5.5. GPT-5/Codex models use the /v1/responses endpoint automatically.

Anthropic

from neo.adapters import AnthropicAdapter
adapter = AnthropicAdapter(model="claude-sonnet-4-5-20250929")

Default model: claude-sonnet-4-5-20250929

Google

Note: Requires Python 3.10+ and google-genai>=0.2.0

from neo.adapters import GoogleAdapter
adapter = GoogleAdapter(model="gemini-2.0-flash")

Default model: gemini-2.0-flash. Uses the google-genai SDK.

Ollama

from neo.adapters import OllamaAdapter
adapter = OllamaAdapter(model="llama2")

Extending Neo

Add a New LM Provider

from neo.cli import LMAdapter

class CustomAdapter(LMAdapter):
    def generate(self, messages, stop=None, max_tokens=4096, temperature=0.7):
        # Your implementation
        return response_text

    def name(self):
        return "custom/model-name"

Key Features

  • Fact-Based Memory: Learns from every solution attempt using a scoped, supersession-based fact store
  • Semantic Retrieval: Vector search finds relevant facts via Jina Code embeddings
  • Code-First Generation: No diff parsing failures
  • Scoped Storage: Privacy-first JSON storage in ~/.neo/facts/ with global, org, and project scopes
  • Model-Agnostic: Works with any LM provider
  • The Construct: Curated library of architecture patterns with semantic search
  • Project Indexing: Tree-sitter based multi-language code indexing with FAISS
  • Prompt Enhancement: Analyze and improve prompt effectiveness

Development

Running Tests

# Run all tests
pytest

# Run specific test
pytest tests/test_neo.py

# Run with coverage
pytest --cov=neo

Research & References

Neo's architecture is grounded in peer-reviewed research on code generation, semantic memory, and multi-agent reasoning.

Academic Papers

Semantic Memory & Failure Learning:

  1. ReasoningBank: Systematic Failure Learning and Semantic Anchor Embedding Chen et al., 2025 | arXiv:2509.25140
    • Phase 2: Semantic anchor embedding (pattern+context, not full reasoning)
    • Phase 3: Failure root cause extraction with contrastive learning
    • Phase 4: Self-contrast consolidation (archetypal vs spurious patterns)
    • Phase 5: Strategy evolution tracking (procedural/adaptive/compositional)
    • Implementation: Neo's persistent memory system with failure signatures

Code Generation & Planning:

  1. Planning with Large Language Models for Code Generation Liu et al., ICLR 2023 | Paper

    • Planning-guided test-driven decoding (PG-TD)
    • Step-level preconditions and exit criteria
    • Implementation: Neo's PlanStep schema with preconditions/exit_criteria fields
  2. Self-Planning Code Generation with Large Language Models Zhang et al., 2023 | arXiv:2303.06689

    • Two-phase plan-then-generate workflow
    • +7% improvement on HumanEval-X Pass@1
    • Implementation: Neo's planning phase before code generation
  3. AdaCoder: Adaptive Planning and Multi-Agent Framework for Function-Level Code Generation Huang et al., 2025 | arXiv:2407.13433

    • Task decomposition with planning, generation, and testing agents
    • Explicit risk assessment per step
    • Implementation: Neo's estimated_risk and verifier_checks fields

Multi-Agent Reasoning:

  1. MapCoder: Multi-Agent Code Generation for Competitive Programming Islam et al., 2024 | arXiv:2405.11403 GitHub
    • Solver-Critic-Verifier agent collaboration
    • Step-level verification and critique
    • Implementation: Neo's verifier_checks and multi-phase reasoning

Retrieval & Similarity:

  1. CodeSim: Effective Semantic Similarity Metrics for Code Xu et al., 2023 | Paper
    • Code-specific similarity metrics for retrieval
    • Step-scoped vs global retrieval tradeoffs
    • Implementation: Neo's retrieval_keys for per-step memory access

Agent Architectures:

  1. As-Needed Decomposition and Planning with Language Models Yao et al., NAACL 2024 | arXiv:2311.05772

    • Selective planning (seed → expand when blocked)
    • Avoids over-planning on simple tasks
    • Implementation: Neo's expanded flag and incremental planning design
  2. Large Language Model-Based Multi-Agents: A Survey of Progress and Challenges Wang et al., 2024 | arXiv:2402.01680

    • Task decomposition, plan selection, and reflection as standard components
    • Multi-agent coordination patterns
    • Implementation: Neo's architectural foundations

Technologies & Libraries

Embedding & Search:

  • Jina Embeddings v2 (Code) HuggingFace | GitHub

    • 768-dimensional embeddings optimized for code similarity
    • Local inference (no API calls)
    • Used in: Neo's semantic memory and pattern retrieval
  • FAISS (Facebook AI Similarity Search) GitHub | Docs

    • Efficient vector similarity search and clustering
    • Billion-scale index support
    • Used in: Neo's fast pattern matching (<13ms avg)
  • FastEmbed GitHub | Docs

    • Lightweight local embedding generation
    • ONNX Runtime backend
    • Used in: Neo's local embedding pipeline

Datasets (for Load Program):

  • MBPP (Mostly Basic Programming Problems) HuggingFace | Paper

    • 1,000 crowd-sourced Python programming problems
    • Used for: Bootstrapping Neo's semantic memory
  • HumanEval HuggingFace | Paper

    • 164 hand-written programming problems
    • Used for: Quality pattern seeding

Citation

If you use Neo in academic research, please cite:

@software{neo2025,
  title={Neo: Self-Improving Code Reasoning Engine with Persistent Semantic Memory},
  author={Parslee AI},
  year={2025},
  url={https://github.com/Parslee-ai/neo},
  note={Built on ReasoningBank (Chen et al., 2025), MapCoder (Islam et al., 2024), and CodeSim (Xu et al., 2023)}
}

License

Apache License 2.0 - See LICENSE for details.

Contributing

See CONTRIBUTING.md for contribution guidelines.

Changelog

See CHANGELOG.md for version history.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

neo_reasoner-0.16.0.tar.gz (423.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

neo_reasoner-0.16.0-py3-none-any.whl (266.0 kB view details)

Uploaded Python 3

File details

Details for the file neo_reasoner-0.16.0.tar.gz.

File metadata

  • Download URL: neo_reasoner-0.16.0.tar.gz
  • Upload date:
  • Size: 423.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for neo_reasoner-0.16.0.tar.gz
Algorithm Hash digest
SHA256 e6741e57a72a7561ace244f8672875239cfe06f3fc07d0de50e749818f121c06
MD5 ae53eaff26b6b3ded9c07e07df732fcd
BLAKE2b-256 66f792b3c12457833d4fe41a56fa6d628c7d0eb5c82215b4e4728148d94ced0e

See more details on using hashes here.

Provenance

The following attestation bundles were made for neo_reasoner-0.16.0.tar.gz:

Publisher: publish.yml on Parslee-ai/neo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file neo_reasoner-0.16.0-py3-none-any.whl.

File metadata

  • Download URL: neo_reasoner-0.16.0-py3-none-any.whl
  • Upload date:
  • Size: 266.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for neo_reasoner-0.16.0-py3-none-any.whl
Algorithm Hash digest
SHA256 18eab080a9fb8a8dd237593a84769c506924ea5b706597159322f76e5cf6ad9e
MD5 c72de3a72b5dad6a55513d13f3030039
BLAKE2b-256 c511a0e843367dfec833c214297c486b40e36ef5adc31ad8a45b75ce96659234

See more details on using hashes here.

Provenance

The following attestation bundles were made for neo_reasoner-0.16.0-py3-none-any.whl:

Publisher: publish.yml on Parslee-ai/neo

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page