{"id":46169987,"url":"https://github.com/aetherwing-io/fcp-core","last_synced_at":"2026-03-05T17:03:29.335Z","repository":{"id":341072268,"uuid":"1168658948","full_name":"aetherwing-io/fcp-core","owner":"aetherwing-io","description":"File Context Protocol — shared framework for building MCP servers (TypeScript + Python)","archived":false,"fork":false,"pushed_at":"2026-03-04T18:14:11.000Z","size":534,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-04T21:28:37.422Z","etag":null,"topics":["framework","llm","mcp","model-context-protocol","python","typescript"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aetherwing-io.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-27T16:43:09.000Z","updated_at":"2026-03-04T18:14:17.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/aetherwing-io/fcp-core","commit_stats":null,"previous_names":["aetherwing-io/fcp-core"],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/aetherwing-io/fcp-core","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aetherwing-io%2Ffcp-core","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aetherwing-io%2Ffcp-core/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aetherwing-io%2Ffcp-core/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aetherwing-io%2Ffcp-core/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aetherwing-io","download_url":"https://codeload.github.com/aetherwing-io/fcp-core/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aetherwing-io%2Ffcp-core/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30137265,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-05T16:58:46.102Z","status":"ssl_error","status_checked_at":"2026-03-05T16:58:45.706Z","response_time":93,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["framework","llm","mcp","model-context-protocol","python","typescript"],"created_at":"2026-03-02T14:28:00.133Z","updated_at":"2026-03-05T17:03:29.318Z","avatar_url":"https://github.com/aetherwing-io.png","language":"Python","readme":"# fcp-core\n\nShared framework for building [FCP](https://github.com/aetherwing-io/fcp) servers -- dual TypeScript and Python implementations.\n\n## What It Does\n\nFCP (File Context Protocol) is an application framework for building MCP servers that let LLMs interact with complex file formats through a verb-based DSL. fcp-core provides the foundational plumbing that every FCP server shares: tokenization, operation parsing, verb dispatch, event sourcing (undo/redo), session lifecycle, response formatting, and a server factory that wires it all together. FCP is to MCP what React is to the DOM -- the LLM thinks in domain operations, FCP renders them into the target format.\n\n## Quick Example\n\nEvery FCP server exposes exactly 4 MCP tools:\n\n| Tool | Purpose | Parameter |\n|------|---------|-----------|\n| `{domain}(ops)` | Batch mutations | `ops: string[]` |\n| `{domain}_query(q)` | Read-only inspection | `q: string` |\n| `{domain}_session(action)` | Session lifecycle | `action: string` |\n| `{domain}_help()` | Reference card | -- |\n\nAll operations follow a common grammar:\n\n```\nVERB [positionals...] [key:value params...] [@selectors...]\n```\n\nCreating an FCP server with `createFcpServer`:\n\n```typescript\nimport { createFcpServer } from '@aetherwing/fcp-core';\n\nconst server = createFcpServer({\n  domain: 'midi',\n  verbs: { note: handleNote, chord: handleChord, tempo: handleTempo },\n  queries: { map: handleMap, describe: handleDescribe },\n});\n```\n\nPython equivalent with `create_fcp_server`:\n\n```python\nfrom fcp_core import create_fcp_server\n\nserver = create_fcp_server(\n    domain=\"midi\",\n    verbs={\"note\": handle_note, \"chord\": handle_chord, \"tempo\": handle_tempo},\n    queries={\"map\": handle_map, \"describe\": handle_describe},\n)\n```\n\n## Installation\n\n**TypeScript** (Node \u003e= 22):\n\n```bash\nnpm install @aetherwing/fcp-core\n```\n\n**Python** (\u003e= 3.11):\n\n```bash\npip install fcp-core\n```\n\n## Architecture\n\nfcp-core provides these modules in both TypeScript and Python:\n\n| Module | Purpose |\n|--------|---------|\n| **Tokenizer** | Quote-aware splitting of operation strings |\n| **Parsed Op** | Structural classification into verb, positionals, params, selectors |\n| **Verb Registry** | Registration and dispatch of domain verb handlers |\n| **Event Log** | Append-only event sourcing with undo/redo and checkpoints |\n| **Session** | Lifecycle management (new, open, save, checkpoint, undo, redo) |\n| **Formatter** | Response prefix conventions (`+` created, `~` connected, `*` modified, `-` deleted) |\n| **Server** | Factory that wires everything into an MCP server |\n\nThe full specification lives in [`spec/`](spec/):\n\n- [grammar.md](spec/grammar.md) -- Tokenization and token classification\n- [tools.md](spec/tools.md) -- The 4-tool architecture contract\n- [session.md](spec/session.md) -- Session lifecycle actions\n- [events.md](spec/events.md) -- Event log and undo/redo\n- [conformance.md](spec/conformance.md) -- Conformance requirements for FCP servers\n\n## Development\n\n```bash\n# TypeScript\ncd typescript\nnpm install\nnpm test          # vitest, 107 tests\nnpm run build     # tsc\n\n# Python\ncd python\nuv sync\nuv run pytest     # 112 tests\n```\n\n## License\n\nMIT\n\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faetherwing-io%2Ffcp-core","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faetherwing-io%2Ffcp-core","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faetherwing-io%2Ffcp-core/lists"}