Skip to main content

The missing cognitive primitive for AI agents. Structured intelligence from any text.

Project description

Decompose

CI PyPI Python

Stop prompting. Start decomposing.

The missing cognitive primitive for AI agents. Decompose turns any text into classified, structured semantic units — instantly. No LLM. No setup. One function call.


Before: your agent reads this

The contractor shall provide all materials per ASTM C150-20. Maximum load
shall not exceed 500 psf per ASCE 7-22. Notice to proceed within 14 calendar
days of contract execution. Retainage of 10% applies to all payments.
For general background, the project is located in Denver, CO...

After: your agent reads this

[
  {
    "text": "The contractor shall provide all materials per ASTM C150-20.",
    "authority": "mandatory",
    "risk": "compliance",
    "type": "requirement",
    "irreducible": true,
    "attention": 8.0,
    "entities": ["ASTM C150-20"]
  },
  {
    "text": "Maximum load shall not exceed 500 psf per ASCE 7-22.",
    "authority": "prohibitive",
    "risk": "safety_critical",
    "type": "constraint",
    "irreducible": true,
    "attention": 10.0,
    "entities": ["ASCE 7-22"]
  }
]

Every unit classified. Every standard extracted. Every risk scored. Your agent knows what matters.


Install

pip install decompose-mcp

Use as MCP Server

Add to your agent's MCP config (Claude Code, OpenClaw, Cursor, etc.):

{
  "mcpServers": {
    "decompose": {
      "command": "uvx",
      "args": ["decompose-mcp", "--serve"]
    }
  }
}

Your agent gets two tools:

  • decompose_text — decompose any text
  • decompose_url — fetch a URL and decompose its content

Use as CLI

# Pipe text
cat spec.txt | decompose --pretty

# Inline
decompose --text "The contractor shall provide all materials per ASTM C150-20."

# Compact output (smaller JSON)
cat document.md | decompose --compact

Use as Library

from decompose import decompose

result = decompose("The contractor shall provide all materials per ASTM C150-20.")

for unit in result["units"]:
    print(f"[{unit['authority']}] [{unit['risk']}] {unit['text'][:60]}...")

What Each Field Means

Field Values What It Tells Your Agent
authority mandatory, prohibitive, directive, permissive, conditional, informational Is this a hard requirement or background?
risk safety_critical, compliance, financial, contractual, advisory, informational How much does this matter?
type requirement, definition, reference, constraint, narrative, data What kind of content is this?
irreducible true/false Must this be preserved verbatim?
attention 0.0 - 10.0 How much compute should the agent spend here?
entities standards, codes, regulations What formal references are cited?
actionable true/false Does someone need to do something?

Why No LLM?

Decompose runs on pure regex and heuristics. No Ollama, no API key, no GPU, no inference cost.

This is intentional:

  • Fast: <500ms for a 50-page spec
  • Deterministic: Same input always produces same output
  • Offline: Works air-gapped, on a plane, on CI
  • Composable: Your agent's LLM reasons over the structured output — decompose handles the preprocessing

The LLM is what your agent uses. Decompose makes whatever model you're running work better.


Built by Echology

Decompose is extracted from AECai, a document intelligence platform for Architecture, Engineering, and Construction firms. The classification patterns, entity extraction, and irreducibility detection are battle-tested against thousands of real AEC documents — specs, contracts, RFIs, inspection reports, pay applications.

License: Proprietary — Copyright (c) 2025-2026 Echology, Inc.

Philosophy: All intelligence begins with decomposition.

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

decompose_mcp-0.1.0.tar.gz (33.0 kB view details)

Uploaded Source

Built Distribution

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

decompose_mcp-0.1.0-py3-none-any.whl (14.6 kB view details)

Uploaded Python 3

File details

Details for the file decompose_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: decompose_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 33.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for decompose_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 9d47ba99b335edbcf2ba54c1ea0aaa7af7f6a1d0281857a48661bda4b41f9786
MD5 c34a7c00cf301b6b914c1ab2582d4281
BLAKE2b-256 aba9532b98651c6b1cfe2b9f0e681023af43855e3701a531609e9d52fef7efba

See more details on using hashes here.

File details

Details for the file decompose_mcp-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: decompose_mcp-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 14.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for decompose_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ed6fa4f92086325da8e58f5c467a81cd0cb7900e8c22b3aa3e3b5efcc40c165f
MD5 5614f331a5eb3c937850e627a50378bd
BLAKE2b-256 855994af4793ea23a425b94e36e63f159112e516e216678ae0cbd59d1fb49224

See more details on using hashes here.

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