Skip to content

Repository files navigation

CodeMesh

CodeMesh is a local-first, C#/.NET-focused context and change-impact service that helps coding agents locate implementation, trace likely impact, and select validation using compact, source-backed evidence.

The current milestone is to establish repeatable evidence that the configured/onboarded workflow improves agent outcomes over normal repository exploration. CodeMesh is not presented as production-ready. The CodeMesh source is available under the MIT License.

Product status

StatusCapability
Implemented and locally verifiedC# ingestion through Roslyn; graph/content persistence; stable checkout identity and bounded local snapshots; repository freshness; REST, MCP, CLI, and .NET Agent Access; default normal and diagnostic MCP profiles; canonical manual onboarding; source spans; relationship-aware context packages; deterministic fixture evaluation; security redaction tests.
Optional and environment-dependentNeo4j, MongoDB, and Qdrant stores; Docker Compose; embeddings through a configured local provider; Python, Markdown, and deployment-artifact parsing with narrower relationships than C#.
Retained, bounded evidenceSummary-free live retrieval passed on two repositories; assisted campaigns replicated utility after explicit onboarding; spontaneous and prompt-parity campaigns recorded zero CodeMesh adoption. These results do not establish broad generalization.
Experimental or unqualifiedGenerated summaries, online model providers, model-selection benchmarks, and the read-only local web UI as a product surface. No summary model is CodeMesh-qualified.
PlannedUnambiguous checkout binding, fail-closed package freshness, a provider-free live runtime probe, reviewable installation, configured/onboarded evaluation, configurable ingestion allow/deny policy, shared-service identity controls, and broader parser and SDLC coverage.

Passing tests establish the covered local behavior. They do not establish hosted CI success, generalized agent benefit, release readiness, deployment acceptance, or production fitness. See Project Status for the reviewed evidence position and Next Steps for execution order.

Architecture

flowchart LR
Repo[Repository ingestion] --> Parsers[Roslyn and local parsers]
Parsers --> Graph[(Neo4j graph)]
Parsers --> Content[(MongoDB content)]
Parsers --> Vector[(Qdrant vectors)]
Graph --> Access[Agent Access REST and MCP]
Content --> Access
Vector --> Access
Access --> Agent[Coding agent]
Loading

Graph paths, generated summaries, and search rankings are navigation evidence. The cited repository source remains authoritative.

Five-minute local demonstration

Prerequisites are the .NET 10 SDK, Docker Compose, Python 3.12 or newer, and uv. The demonstration indexes this checkout, so it needs no external sample repository or model provider.

  1. Create local configuration and set a unique development password:

    Copy-Item .env.example .env
    # Edit .env and set CODEMESH_NEO4J_AUTH=neo4j/<random-local-password>

    On Unix-like shells, use cp .env.example .env instead. .env is ignored by Git. The example keeps model and summary providers disabled.

  2. Start the local stores and parser, then ingest CodeMesh without embeddings or generated summaries:

    docker compose up -d neo4j mongodb qdrant csharp-parser agent-access
    dotnet restore CodeMesh.sln --locked-mode
    dotnet run --project src/CodeMesh.Cli -- self ingest --skip-embeddings
  3. Query the repository through Agent Access:

    Set-Location agent-access
    uv sync --locked
    uv run python -m codemesh_agent_access package `"How does self ingestion reach the stores?"`--repository-id code_mesh `--output agent

The generated alias is normally code_mesh; confirm it with dotnet run --project src/CodeMesh.Cli -- repos list if needed. For a store-free contract demonstration, run uv run python -m codemesh_agent_access eval from agent-access; that suite uses synthetic in-process fixtures and proves tool behavior, not retrieval from a live index.

What this demonstrates

  • .NET 10 and Roslyn-based semantic parsing for C# implementation and local relationships.
  • Python FastAPI, MCP, CLI, ranking, formatting, and store read paths.
  • Neo4j graph, MongoDB content/registry, and optional Qdrant vector storage.
  • Docker Compose service wiring with host ports restricted to loopback by default.
  • Source-scoped MCP context packages with freshness and redaction diagnostics.
  • Deterministic fixture, live retrieval, and opt-in agent/model evaluation layers with explicit evidence boundaries.
  • Local-first processing by default; generated summaries and external model providers are opt-in and unqualified.

Verification

Use the risk-scaled commands in Testing. Current status and retained product evidence are summarized in Project Status; dated results apply only to the commits they identify.

Repository map

  • src/CodeMesh.Parser.CSharp: Roslyn parser worker.
  • src/CodeMesh.Ingestion: ingestion, cleanup, redaction, embeddings, and optional summary generation.
  • src/CodeMesh.Storage: Neo4j, MongoDB, Qdrant, and in-memory adapters.
  • src/CodeMesh.Control and src/CodeMesh.Cli: configuration, lifecycle, and operator commands.
  • agent-access: Python REST, MCP, CLI, ranking, and evaluation surfaces.
  • tests/CodeMesh.Tests and agent-access/tests: .NET and Python verification.

Start with Agent Quickstart when working in the repository. The Documentation Hub organizes current references, guides, status, evidence, engineering policy, and future proposals.

Security, contribution, and licence

Read SECURITY.md before reporting a suspected secret or vulnerability, CONTRIBUTING.md before proposing changes, and the Code of Conduct when participating in the project.

CodeMesh is licensed under the MIT License. Third-party packages, services, and referenced evaluation repositories retain their own licences; see Third-party Notices. The dated Publication Readiness Review is retained as historical evidence for its recorded checkout, not as current readiness status.

About

Local-first C#/.NET context and change-impact service for coding agents, with source-grounded REST, MCP, CLI, and .NET access.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages