Skip to content
Projetos

Sobre

The programming language that checks your AI before it runs.

Linguagens e ambientes de execução

Como estes números são medidos

O que você pode fazer

  • Web applications with server-rendered views, forms and browser controls. Browser views
  • HTTP services with typed routes, JSON, uploads, sessions, roles, OAuth and OpenAPI. Backend guide
  • Agents with typed tools, approvals, budgets, step limits, evaluations and replay. Prompts
  • Data work with typed tables on SQLite and Postgres (typed rows and queries, revision-checked writes, atomic blocks and migrations planned from the declarations), HTTP, files and JSON. Tables · Talking to the outside world

Crescimento medido de estrelas

em 24 h
0
em 7 dias
0
em 15 dias
0
em 1 mês
Coletando histórico

Variações líquidas em períodos sobrepostos, não totais diários. Medições ausentes ficam em branco. Estrelas indicam interesse, não qualidade.

README.md

Original

Corvid

Build the whole application — interface, backend and AI — in one language, where people and AI agents use the same typed actions.

Corvid is a general-purpose programming language. A small app takes a few lines, and a team can build a large AI application at full scale from the first day with the same grammar, types and tools. Anything you build on the backend and AI side with Python or TypeScript and their libraries is meant to be buildable in Corvid, through built-in features or typed interoperability.

Corvid is pre-1.0 and under active development. This page shows only what runs today and says plainly what is still being built. The platform plan describes what comes next.

Why one language for the interface, backend and AI

Today one feature is split across a database, a backend in one language, a frontend in another and an AI layer added on top, each with its own types, validation and permissions, kept in step by hand. Corvid puts them in one program that one compiler understands:

  • One definition, everywhere. A type or a table is declared once and used by the database, the backend, the interface and the AI. Rename a field and the compiler points at every place that uses it, instead of a user finding the break in production.
  • The API keeps itself in sync. The backend publishes a typed contract, and the TypeScript client and the Swift, Kotlin and Python SDKs are generated from it, so a client cannot drift from the server.
  • People and AI use the same actions. A button and an assistant can run the same handler. There is no second API to build and secure for the agent, and the author chooses what an assistant may call.
  • No glue code. No hand-written client, no duplicated validation, and migrations planned from the table declarations.

Next, an action is declared once, with its input, permission, validation and conflict rule, and the compiler derives the button, the endpoint and the assistant tool from it. After that, assistants see the current screen's typed state instead of screenshots, and one timeline follows a request across the interface, backend, agent and model steps.

The problems every team adding AI runs into

The problem What Corvid does
Model output is untyped text. A parser breaks the day the model phrases things differently. A prompt returns a declared type. When a reply does not match, Corvid sends the model the exact error and asks again.
A bad answer cannot be reproduced. The same input gives a different result, so it cannot be debugged. Model calls, tool calls and approvals are recorded, and corvid replay runs a trace again with the same results, without calling the model.
The bill is the first sign of the cost. Declare a budget, and code that could exceed it does not compile.
An agent can call anything. One injected instruction in a page can make it act on your data. An irreversible tool needs an approve step, and text marked untrusted cannot reach it. Both are checked before the program runs.
A grounded answer looks like an invented one. Values from retrieval carry their sources as Grounded<T>, and the compiler refuses to present an unsourced value as grounded.
Testing AI features is guesswork. Tests, evaluations, fixtures and mocks are part of the language, and a recorded run can become a test.
One AI feature touches four codebases. Declare a table once and get typed rows, typed queries and planned migrations, on SQLite or Postgres.

The sections below show each of these running.

The application and the AI see each other

One compiler sees every screen, action, type, permission, effect and cost in the application. So Corvid can give an AI the application itself, instead of screenshots or a hand-written API, and show people everything the AI does.

identity users:
    provider google
    provisioning:
        first_login: open
        tenant: fixed("public")
    roles:
        editor: "board.edit"
    delegation: up_to 8 hours

type Column:
    | Todo
    | Done

type MoveCard:
    card: Int
    to: Column
    position: Int where between(0, 500)

type Moved:
    card: Int
    position: Int

action move_card(move: MoveCard, by: Caller) -> Moved requires permission("board.edit"):
    assistants: allow "Move a card to another column."
    return Moved(move.card, move.position)

action archive_card(card: Int, by: Caller) -> Int requires permission("board.edit"):
    assistants: confirm "Archive a card."
    return card

agent board_controls(card: Int) -> String:
    move = form_for(move_card, MoveCard(card, Done, 0), "Move")
    archive = button_for(archive_card, card, "Archive")
    return move + archive

People sign in through the identity block, and its roles say who holds board.edit. An action is declared once: its typed input, who may call it, its validation (position between 0 and 500), and whether an assistant is offered it. The page's form and button, the HTTP endpoint and an authorized assistant all use that one definition, so there is no separate agent API. assistants: allow lets an assistant move a card within its person's own permission; assistants: confirm makes each archive wait for the person. An action with no assistants: line is offered to people only. Rename a field of MoveCard and the compiler points at the form, the endpoint's callers and the assistant's schema. Run it: corvid tour --topic shared-actions.

Try it

Install on macOS or Linux (Windows instructions are under Install):

curl -fsSL https://raw.githubusercontent.com/Micrurus-Ai/Corvid-lang/main/install/install.sh | sh

The installer also adds the Corvid extension to VS Code, Cursor, VSCodium and Windsurf when it finds them. Then create and run a project:

corvid new hello
cd hello
corvid run

Continue with the five-minute quickstart, or run corvid tour --list to see each language feature as a runnable demo. The new project's AI step runs straight away with no account or API key, from a model answer saved with the project. Change the question and corvid run --live --record asks your model once and keeps the answer. The quickstart's own model step still needs a model provider for now.

What the compiler checks for you

Model output has a type. A prompt returns a declared type. When a reply does not match, with repair sends the model the exact error and asks again, and the budget counts every attempt:

type Triage:
    category: String
    urgent: Bool

effect llm_call:
    cost: $0.01

prompt classify(ticket: String) -> Triage uses llm_call:
    with repair 2
    "Classify this support ticket: {ticket}"

@budget($0.05)
agent triage(ticket: String) -> Triage:
    return classify(ticket)

Three attempts at $0.01 fit the $0.05 budget. Raise the cost to $0.02 and the program no longer compiles: static worst-case cost exceeds the declared budget.

Actions with consequences need approval. An agent cannot call an irreversible tool without an approve step on the line before it:

type Receipt:
    id: String

effect transfer_money:
    cost: $0.50
    trust: human_required
    reversible: false

tool issue_refund(id: String) -> Receipt dangerous uses transfer_money

@budget($1.00)
@trust(human_required)
agent refund(id: String) -> Receipt:
    approve IssueRefund(id)
    return issue_refund(id)

Delete the approve line and the compiler stops with this call needs prior approval and suggests the line to add.

Data from outside has a type. Order.from_json(text) decodes JSON into a declared type, and an error names the field that did not match:

type Order:
    id: Int
    note: Option<String>

agent order_id(text: String) -> Result<Int, String>:
    order = Order.from_json(text).map_err(fn (e) -> e.path + ": " + e.message)?
    return Ok(order.id)

HTTP routes, the published OpenAPI schema and the generated TypeScript client all use the same JSON mapping, so the backend and its callers cannot disagree about a record's shape.

Every run can be replayed. Model calls, tool calls and approvals are recorded, and corvid replay runs a recorded trace again with the same results, without calling the model or repeating side effects. Values that come from retrieval carry their sources as Grounded<T>, and the compiler refuses to present an unsourced value as grounded.

What you can build today

  • Web applications with server-rendered views, forms and browser controls. Browser views
  • HTTP services with typed routes, JSON, uploads, sessions, roles, OAuth and OpenAPI. Backend guide
  • Agents with typed tools, approvals, budgets, step limits, evaluations and replay. Prompts
  • Data work with typed tables on SQLite and Postgres (typed rows and queries, revision-checked writes, atomic blocks and migrations planned from the declarations), HTTP, files and JSON. Tables · Talking to the outside world
  • Background work with durable jobs, schedules, retries and restart recovery.

What is missing compared with Python and TypeScript is listed honestly in the backend and AI audit.

Where Corvid is going

The platform plan organizes the next work around one principle: the application and the AI can always see each other, within what the author declares.

  • The first hour: a first project that runs with no API key, a flagship task-board demo, and a compiler that coding assistants can ask what calls what and what a change breaks.
  • The application and the AI see each other: typed shared actions, assistants that see the current screen's typed state, agent activity people can review and undo, live shared state, and one debugging timeline across interface, backend, agent and model steps.
  • Breadth and performance: typed Python and npm interoperability on every target, typed persistence, real-time connections, vector search, tensors with checked shapes, and published benchmarks on equivalent workloads.

Invention catalog

Each entry has a runnable tour, a specification and tests. The full catalog has every entry's example and scope, and the proof matrix lists the tests behind each one.

Area Invention Try it
Safety At Compile Time Approve Before Dangerous corvid tour --topic approve-gates
Safety At Compile Time Dimensional Effects corvid tour --topic dimensional-effects
Safety At Compile Time Grounded<T> Provenance corvid tour --topic grounded-values
Safety At Compile Time Strict Citation Contracts corvid tour --topic strict-citations
Safety At Compile Time Provenance Propagation + @grounded_pure corvid tour --topic provenance-propagation
Safety At Compile Time Compile-Time Budgets corvid tour --topic cost-budgets
Safety At Compile Time Confidence Gates corvid tour --topic confidence-gates
Safety At Compile Time Secrets That Never Reach a Trace, a Prompt or a Log corvid tour --topic secrets
AI-Native Ergonomics AI-Native Keywords corvid tour --topic language-keywords
AI-Native Ergonomics Trace-Aware Evals corvid tour --topic eval-traces
AI-Native Ergonomics Local Models With Checked Tensors corvid tour --topic local-models
AI-Native Ergonomics Malformed Output Cannot Happen corvid tour --topic constrained-generation
AI-Native Ergonomics Embeddings That Know Their Model corvid tour --topic embeddings
AI-Native Ergonomics Transcripts That Cannot Give Orders corvid tour --topic speech-to-text
AI-Native Ergonomics Fan Out Within a Written Limit corvid tour --topic dynamic-fan-out
AI-Native Ergonomics Overnight AI Work, Paid For Once corvid tour --topic batch-requests
AI-Native Ergonomics Every Kind of Model, One Declaration corvid tour --topic every-kind-of-model
AI-Native Ergonomics Replay And Receipts corvid tour --topic replay-receipts
AI-Native Ergonomics Effect-Audited Skills —
AI-Native Ergonomics Typed MCP In One Command —
AI-Native Ergonomics Prompt Injection Is a Compile Error corvid tour --topic injection-taint
AI-Native Ergonomics Replay-Safe Secret Access corvid tour --topic replay-safe-secrets
AI-Native Ergonomics Provenance-Keyed Cache corvid tour --topic provenance-cache
AI-Native Ergonomics Governed Cron —
AI-Native Ergonomics Replay Quarantine For Durable Jobs corvid tour --topic replay-quarantine
Adaptive Routing Typed Model Routing corvid tour --topic model-routing
Adaptive Routing Progressive Refinement corvid tour --topic progressive-routing
Adaptive Routing Ensemble Voting corvid tour --topic ensemble-voting
Adaptive Routing Jurisdiction And Privacy Routing corvid tour --topic privacy-routing
Streaming Streaming Effects corvid tour --topic streaming-effects
Streaming Progressive Structured Streams corvid tour --topic partial-streams
Streaming Typed Items As The Model Writes Them corvid tour --topic typed-item-streams
Streaming Typed Stream Resumption corvid tour --topic stream-resume
Streaming Declarative Fan-Out / Fan-In corvid tour --topic stream-fanout
Verification Proof-Carrying Dimension Registry corvid tour --topic effect-registry
Verification Adversarial Bypass Testing corvid tour --topic adversarial-tests
Verification Executing File-I/O Surface corvid tour --topic file-io
Verification Declared HTTP Client corvid tour --topic http-client
Verification Executing SQLite Surface corvid tour --topic sqlite
Verification Executing JSON Surface (Opaque + Typed) corvid tour --topic json
Verification Governed Retrieval (retired: use typed tables) corvid tour --topic governed-retrieval
Verification MCP With Governance —
Verification Governed Concurrency —
Verification Executing Time & Randomness Surface corvid tour --topic deterministic-time
Verification The Agent Graph, Drawn from the Code corvid tour --topic agent-graph
Verification Ask the Compiler, Not the Text corvid tour --topic compiler-questions
The Application Surface Define Once, Get Everything corvid tour --topic application-surface
The Complete Application Runtime The Backend Proves Its Own Contract, Or Refuses To Start corvid tour --topic contract-closure
The Complete Application Runtime Cancel Fast, But Never Past a Point of No Return corvid tour --topic parallel-cancellation
The Complete Application Runtime OAuth Login That's Safe By Construction corvid tour --topic oauth-login
The Complete Application Runtime Protocol-Typed Connectors corvid tour --topic connectors
The Complete Application Runtime Verified Provider Protocols corvid tour --topic verified-provider-protocols
The Complete Application Runtime Typed Tables With Revision-Checked Writes corvid tour --topic tables
The Complete Application Runtime One Action for People and Assistants corvid tour --topic shared-actions

Architecture

source .cor
  -> lex / parse
  -> resolve names
  -> typecheck
  -> effect, budget, confidence, grounding, approval, routing checks
  -> typed IR
  -> interpreter, native Cranelift backend, Python backend, WASM backend
  -> traces, replay, receipts, bundles

The language is designed as one compiler pipeline with multiple execution tiers. Safety properties belong in the shared frontend and IR, not in one backend's runtime glue.

Status

Corvid is pre-v1.0 and under active development. The compiler, interpreter, effect system, model substrate, streaming substrate, replay/bundle infrastructure, native backend, signed cdylib attestation, separate-binary ABI descriptor verifier, and claim explanation workflow are in the repository today. Some backend paths intentionally reject newer high-level features until parity work lands; signed builds fail closed when contract-like syntax is not mapped to a registered guarantee.

A 2026-04-29 internal audit of Phases 35-41 found four phase-done bullets in Phases 38-41 that were structurally absent (multi-worker job runner + crash-recovery / DST tests, real JWT verification + corvid auth/approvals CLI, OTel SDK conformance, connector real mode + corvid connectors CLI). The ROADMAP now carries audit-correction tracks (35-N, 38K-M, 39K-L, 40J-K, 41K-M) that close the gaps end-to-end. Slice checkmarks before those tracks land are honest only at the layer the slice named — composition with the surfaces above stays disabled.

Use the roadmap for source-of-truth status:

rg -n "^- \\[ \\]" ROADMAP.md

Install

Windows (PowerShell):

irm https://raw.githubusercontent.com/Micrurus-Ai/Corvid-lang/main/install/install.ps1 | iex

macOS / Linux:

curl -fsSL https://raw.githubusercontent.com/Micrurus-Ai/Corvid-lang/main/install/install.sh | sh

The installer downloads a prebuilt corvid for your OS/arch into ~/.corvid/, adds ~/.corvid/bin to your PATH, and runs corvid doctor. If a prebuilt archive is not available for your platform, it falls back to a cargo install from source.

Override defaults with CORVID_REPO, CORVID_VERSION (e.g. v0.1.0), or CORVID_HOME.

Or via your package manager (planned, post-v1.0)

Status: the install scripts above (install/install.{sh,ps1}) are the canonical install path for Corvid v1.0. The package- manager manifests below are tracked as Phase 33P slices in ROADMAP.md and ship post-v1.0 — none of them is the "installer," each is additive metadata that a language-installer manager's central repo consumes and routes back to the GitHub Release artifacts release.yml produces. They're filed but not built yet; running them today will report "formula/manifest not found."

Manager End-user command (post-v1.0) Filed slice
Homebrew (macOS / Linux) brew install Micrurus-Ai/corvid/corvid 33P1-homebrew-tap
Scoop (Windows) scoop bucket add corvid https://github.com/Micrurus-Ai/scoop-corvid && scoop install corvid 33P2-scoop-bucket
winget (Windows) winget install Micrurus-Ai.Corvid 33P3-winget-manifest
Chocolatey (Windows) choco install corvid 33P4-chocolatey-package
AUR (Arch Linux) yay -S corvid-bin (or equivalent AUR helper) 33P5-aur-package
APT / RPM (Debian / Fedora) apt install corvid / dnf install corvid after one-time repo add 33P6-apt-rpm-repo

If you want to track or contribute any of these, ROADMAP.md's Phase 33P block names each filed slice with what it actually does. Manifest contributions are welcome at any time — the GitHub Release artifacts they consume (release.yml) are already shipping; the manifests are post-v1.0 only because Path A defers public packaging-manager listings until launch by deliberate design.

Install From Source

cargo install --path crates/corvid-cli
corvid doctor

Python runtime pieces are only needed when using the Python backend. Native and interpreter work do not require a Python deployment target.

Developer Commands

cargo check --workspace
cargo test --workspace
cargo run -q -p corvid-cli -- tour --list
cargo run -q -p corvid-cli -- check examples/offline_refund_bot/src/refund_bot.cor

If cargo fmt --check fails because cargo-fmt is not installed, install the Rust formatter for the active toolchain before treating formatting as validated.

Documentation

License

Corvid is released under the MIT License.

Contributions are licensed under the same MIT terms (inbound = outbound) unless the contributor marks otherwise.

Explore projetos relacionados

Carregando…