MCPcopy Index your code
hub / github.com/dginev/CorTeX

github.com/dginev/CorTeX @v0.6.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v0.6.0 ↗ · + Follow
1,213 symbols 3,460 edges 118 files 556 documented · 46%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

CorTeX Framework

A general purpose processing framework for corpora of scientific documents

CI Library docs Agent API License version

News: - 2019: arXMLiv Homepage The CorTeX framework is recurringly converting >1.5 million articles from arXiv.org - 2018: SIGMathLing resources First datasets produced by CorTeX are now available for reuse via the SIGMathLing interest group

Features: - [x] Safe and speedy Rust implementation - [x] Distributed processing and streaming data transfers via ZeroMQ - [x] Backend support for Document (via FileSystem) and Task (via PostgreSQL 18+) provenance. - [x] Representation-aware and -independent (TeX, HTML+RDFa, ePub, TEI, JATS, ...) - [x] Powerful workflow management and development support through the CorTeX web interface - [x] Supports multi-corpora multi-service installations - [x] Centralized storage, with distributed computing, motivated to enable collaborations across institutional and national borders. - [x] Routinely tested on 1 million scientific TeX papers from arXiv.org - [x] Self-installing: cortex init / doctor (embedded migrations, runtime config, health check) - [x] Agent-first & symmetric: every capability on three surfaces — web UI, agent JSON API (OpenAPI at /api/docs), and the scriptable cortex CLI — from one shared backend, so all see the same live + historical state - [x] Observability: background-job health, /health + Prometheus /metrics, an audit log of every admin action - [x] Local authentication: passkeys (WebAuthn) + admin tokens, server-side sessions - [ ] Annotations backend and workflow (TODO) - [ ] Automatic dependency management of registered Services (TODO)

Getting started (full steps in INSTALL.md; day-to-day operation in MANUAL.md):

sudo apt install -y postgresql libpq-dev libzmq3-dev libsodium-dev pkg-config
cargo run --bin cortex -- init                                  # migrate + scaffold config
cargo run --bin cortex -- set-admin-token --generate --owner me # first admin credential
cargo run --bin cortex -- doctor                                # verify: => healthy
cargo run --bin frontend                                        # serves http://127.0.0.1:8000

Admin token & secrets: writes and the /admin sign-in are gated by an admin token (sent as an X-Cortex-Token header or ?token= query) mapped to an owner (rerun_tokens). Tokens live in a gitignored token file — the default is config.json in the working directory (the tracked config.example.json is a demo template only, never your real token), scaffolded/managed by cortex set-admin-token. To keep a production token out of the repository entirely, put it in a JSON file outside the tree and point CORTEX_AUTH_FILE at it (it overrides the in-repo config):

# /etc/cortex/config.json  (chmod 600, owned by the service user — never in git)
{ "rerun_tokens": { "<your-token>": "<owner>" } }
# then, in the service environment (e.g. /etc/cortex/frontend.env):
CORTEX_AUTH_FILE=/etc/cortex/config.json

Humans can also sign in with passkeys (WebAuthn); the token is the agent + break-glass credential.

History: * Originally motivated by the desire to process any Cor-pus of TeX documents. * Rust reimplementation of the original Perl CorTeX stack. * Builds on the expertise developed during the arXMLiv project at Jacobs University. * In particular, CorTeX is a successor to the build system originally developed by Heinrich Stamerjohanns. * The messaging conventions are adopted from work on standardizing LaTeXML's log reports with Bruce Miller.

CorTeX is being productized from an admin-only prototype into a self-installing, agent-first + human-first application — an active sprint (see docs/PRODUCTIZING_PLAN.md), with a public preview in preparation. It now self-installs and ships a complete operator manual and agent API, though some hardening/rationalization is still in flight. For details consult the Installation instructions and the Manual. Please feel invited to open an issue with a description of your target workflow!

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Function 789
Method 218
Class 191
Enum 11
Interface 4

Languages

Rust97%
TypeScript3%
Python1%

Modules by API surface

src/frontend/corpora.rs54 symbols
src/frontend/reports.rs49 symbols
bin/cortex.rs47 symbols
src/frontend/management.rs45 symbols
src/helpers.rs42 symbols
src/backend.rs39 symbols
src/frontend/services.rs38 symbols
src/backend/reports.rs38 symbols
src/dispatcher/server.rs37 symbols
src/frontend/concerns.rs36 symbols
public/js/jszip.min.js31 symbols
src/frontend/runs.rs28 symbols

Datastores touched

cortexDatabase · 1 repos
cortex_testerDatabase · 1 repos

For agents

$ claude mcp add CorTeX \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page