Skip to content
formulahendryPublic

About

Use Jev typed decisions from any ACP (Agent Client Protocol) client or IDE

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Repository files navigation

jev-acp

Use Jev typed decisions from any Agent Client Protocol client or IDE.

jev-acp is a decision agent, not a chat model. It evaluates explicit Choice, Score, and Noul questions and returns typed answers, probabilities, and confidence without involving an intermediate LLM.

Screenshot

Jev in JetBrains: review a Choice request, then inspect the selected option, reported confidence, and probability distribution.

Jev Choice task in JetBrains showing the request review and detailed decision results

This screenshot illustrates the interface; the example output is not health advice.

Setup

Requires Node.js 22 or newer and a TypeSafe API key. You do not need to clone this repository or build it to use a published package:

npx -y jev-acp

The agent communicates over ACP stdio, not an interactive terminal chat. Configure your ACP client to launch it and pass TYPESAFE_API_KEY as shown below. Without an explicit version, npx uses the stable latest channel. For preview builds, use npx -y jev-acp@next. Before the first stable release, use the preview channel (once bootstrapped) or local development.

Example vscode-acp or acp-ui configuration:

{
  "agents": {
    "Jev": {
      "command": "npx",
      "args": ["-y", "jev-acp"],
      "env": {
        "TYPESAFE_API_KEY": "..."
      }
    }
  }
}

Use "jev-acp@next" in args to track previews, or an exact version to pin a release. Some Windows clients require command: "cmd" and args: ["/c", "npx", "-y", "jev-acp"] to launch npx.

Start with a task

In your ACP client, open the Task selector. There is no command syntax to learn. New sessions start quietly, without a greeting or numbered menu. Choose one is selected by default, so you can immediately send your options, one per line, or select a different task. There is no empty "Choose a task" option. In the default guide, nothing is evaluated until you finish the input and reply Run. The picker is the only task-selection entry point in this default mode: chat numbers and task-switching commands do not change its selection.

Task What you provide
Choose one Options, one per line, followed by your goal and situation
Score against a rubric A reusable question, ordered levels, and material to assess
Check a statement A proposition and the evidence to evaluate
Built-in: Product feedback One product feedback message
Built-in: Feedback sentiment Text whose expressed sentiment should be assessed
Built-in: Incident impact (reference) A report describing user impact and workarounds

For example, select Choose one, then send:

Standard delivery
Express delivery

The next prompt asks what you want to achieve. Include your selection criteria and relevant situation in the same message:

The package must arrive tomorrow. Cost is less important than delivery time.

The review shows Options and Your requirements, preserving what you entered. If you send a greeting, a single option, or duplicate options first, the agent explains the current Choose one task and gives a two-line example; it does not guess missing options or call Jev.

Review the options and input, then reply Run. Reply Edit to choose what to change, or Save template to reuse the definition. The explicit Edit options and Edit goal replies also remain available. Options may contain spaces and Unicode; you do not need to invent internal IDs. Each screen lists the actions that are available there. Action words are treated as data while collecting options, questions, or evidence. Missing options or an unexpected menu reply produce a short correction, not an internal-error alert. Repeated synchronization of the same task by your client does not restart the guide or ask you to switch tasks.

Check a statement asks for a proposition, then directly asks for the supporting text or situation. Score against a rubric asks for a question and ordered levels, then directly asks for the content to score. Both show one complete review after the material arrives; there is no intermediate Provide content step. Reply Run from that review to evaluate.

These modes assess the information you supply; they do not automatically look up facts. For example, check "This feedback explicitly requests a refund" against a customer's message, or score user impact against an incident report.

To save only a statement or scoring definition before providing material, use /template save <name> after its question and any scoring levels are complete. The guide will continue waiting for material without calling Jev. Ordinary words such as Run or Save template at that step are treated as material, not actions. Saving does not activate the template or change your current input. If a saved template does not appear in the picker, open a new session to load the updated list.

Switch tasks freely: each task keeps its unfinished draft or template edits within the current session. Switch back to resume where you left off, with no Switch / Keep step. /cancel clears only the current task's input, not the task selection or other tasks' drafts. During a decision, cancellation preserves the review for retry. A picker switch cancels a running decision before activating the new task, and late results are ignored.

Clients without a Task picker

Set JEV_ACP_INTERACTION_MODE to chat in the agent process environment:

{
  "env": {
    "JEV_ACP_INTERACTION_MODE": "chat",
    "TYPESAFE_API_KEY": "..."
  }
}

Chat mode exposes only the Output setting. It also starts quietly; send /tasks or an initial message to see the numbered task menu. Select a number, then answer the guide's questions. /tasks and /template use <name> switch tasks while retaining drafts. Use /tasks to leave template management.

The default is picker. Modes are explicit rather than detected by IDE name, and invalid values fail at startup. Embedders can set createJevAgentApp({ interactionMode: "chat" }) (or "picker"). Only chat mode starts without a selected task internally.

Files and editor context

Attached files are not extra options, menu replies, or template names. Only what you type is used for these steps. When supplying decision material, embedded text attachments can be included and are shown as attached text.

A file link alone does not supply file contents: the agent does not open or fetch it. Paste the content if your client only sends a link. If text accompanies a link, the agent evaluates the text and tells you the link was not included. Complete advanced commands use their explicit input, not accompanying files.

Jev is not a general-purpose chat assistant: these guides do not infer arbitrary schemas, invent facts, or automatically select a task for you.

Built-in and saved templates

Selecting a template displays its purpose, question, criteria, and input hint. After that, each ordinary message is evaluated independently using that definition, with no repeated confirmation.

  • Product feedback classifies bug reports, feature requests, usage questions, mixed requests, and other/insufficient information.
  • Feedback sentiment assesses expressed positive, neutral, negative, mixed, or insufficient sentiment, not the author's private mental state.
  • Incident impact (reference) uses a 0-3 availability rubric and a separate evidence check. If evidence is insufficient, the numeric recommendation is withheld and you are asked to supply more details. JSON mode retains the raw result with a warning. This is advisory, not an escalation policy.

Select Manage templates (or use /template manage in chat mode) to:

  • Copy a built-in or user template under a new name.
  • Edit a user template's questions, options, rubric, description, or input hint. Review the changes and reply Save changes to persist them.
  • Delete a user template, with an explicit confirmation.

Built-ins are read-only. Copies preserve their evidence safeguards. Existing names are never silently overwritten, and stale edits are rejected. Template names may contain spaces and Unicode. Back at the management root stays in template management. Choose another task when you want to leave; saving, copying, or cancelling will not move your picker.

Saved templates contain only reusable definitions and presentation metadata, never the current decision input. The choice guide asks for a separate reusable goal when saving, so the situation you just entered is not saved by accident. Templates live in ~/.jev-acp/templates.json; set JEV_ACP_HOME to use a different directory. Existing question-only template files remain supported.

Advanced commands

Complete one-turn commands remain available in both modes without changing the selected task. Legacy multi-turn command input is available in chat mode. In picker mode, incomplete primitive commands direct you to the corresponding Task entry, rather than starting a conflicting workflow.

Choice

/choice Which team should handle this?
billing = Payments, refunds, invoices, and subscriptions
technical = Bugs, outages, and integration failures
sales = Pricing, trials, and purchasing
--
My credit card was charged twice.

Score

/score How severe is this incident?
No user impact
Some users affected
Core service unavailable
--
The payment API returns 502 for every checkout.

Noul

Noul is a probabilistic yes/no judgment. It returns the probability that the statement is true.

/noul This issue requires immediate on-call attention
--
The payment API returns 502 for every checkout.

In chat mode, commands may also be entered without arguments. The agent then collects the question, criteria, and state over several turns.

Multiple questions

/decide accepts a JSON object containing state and questions:

/decide
{
  "state": "The payment API returns 502 for every checkout.",
  "questions": {
    "department": {
      "type": "choice",
      "instructions": "Which team should handle this?",
      "criteria": {
        "billing": "Payments and subscriptions",
        "infrastructure": "Services and outages"
      }
    },
    "page_on_call": {
      "type": "noul",
      "instructions": "This requires immediate on-call attention"
    }
  }
}

Template commands

After a successful decision:

/template save issue-triage

Saving does not activate the template. Select it in the Task picker, or use /template use issue-triage in chat mode.

Once a template is active, ordinary messages are treated as new state for that template. Templates are stored in ~/.jev-acp/templates.json.

Other commands:

/template list
/template manage
/template delete <name>
/template off
/tasks
/history
/cancel
/help

Session configuration

In the default picker mode, the agent exposes two session configuration options:

  • Task: a guided decision, built-in template, user template, or template management
  • Output: concise, detailed, or json

Chat mode exposes only Output. In picker mode, /tasks, /template use|off|manage, and incomplete decision commands point to the picker rather than changing it.

The client owns the visible chat transcript. The agent retains the selected task, independent unfinished drafts, output settings, and recent structured results. Only the current task's explicit input is sent to Jev, never another task's draft or the chat transcript. Drafts do not survive a new session. The legacy template config ID remains accepted in picker mode; clients now display task.

Running, cancellation, and failures are shown in chat. Failed or cancelled guided decisions retain their unfinished input so you can retry. Reported confidence and probabilities are model outputs, not guarantees of accuracy. No generated explanation is presented as Jev's reasoning.

Local development

Only contributors and users running from source need to install dependencies and build:

git clone https://github.com/formulahendry/jev-acp.git
cd jev-acp
npm ci
npm run typecheck
npm run build
npm test
npm pack --dry-run --ignore-scripts

The pack dry run lists the files that would be published without uploading anything. The tests cover source and compiled ACP startup in both interaction modes and do not need a TypeSafe API key.

For development, launch npm run dev, or configure your client to run node with the absolute path to dist/main.js. Set TYPESAFE_API_KEY in the client environment when testing real decisions. Rebuild and restart the agent process after source changes. npm pack also builds automatically via prepack.

CI and npm releases

Event Validation Publication
Pull request to main CI on Ubuntu/Windows and Node 22/24 None
Push to main CI matrix; publish job also validates on Ubuntu/Node 24 next
Manual Publish npm run on main Publish job validates on Ubuntu/Node 24 next
Published, non-prerelease GitHub Release with vX.Y.Z tag Publish job validates the tagged commit and matching package versions latest

.github/workflows/ci.yml runs installation, typecheck, build, tests, and a pack dry run. .github/workflows/npm-publish.yml has two jobs: publish-next and publish-release. Each repeats those checks before calling npm publish directly; publishing does not depend on the separate CI workflow completing. There are no custom release scripts, artifact recovery, GitHub Environments, or enablement variables. No packages are published from pull requests, forks, or manual non-main branches. Workflows never create commits or git tags.

One-time npm trusted publishing setup

  1. The package must already exist on npm before configuring a trusted publisher. If it does not, use a disposable checkout for the first real preview:

    npm ci
    npm run build
    npm test
    npm pack --dry-run --ignore-scripts
    npm version 0.1.0-next.0 --no-git-tag-version
    npm login
    npm publish --tag next --access public

    This is a manual bootstrap, not a CI command. Use your npm account and 2FA, or a short-lived granular token if needed. Do not commit the bootstrap version changes or a credential. A preview-only bootstrap does not create a stable latest release.

  2. In the npm package's Settings > Trusted publishing, add one GitHub Actions connection for both channels:

    Field Value
    Organization or user formulahendry
    Repository jev-acp
    Workflow filename npm-publish.yml
    Environment Leave blank

    Allow direct publishing, not stage-only publishing. The jobs use GitHub-hosted Ubuntu runners, Node 24, a pinned OIDC-capable npm CLI, and id-token: write. No NPM_TOKEN or NODE_AUTH_TOKEN secret is needed. npm automatically generates provenance for this public repository.

  3. Push the workflows or manually run Publish npm on main to verify next. Publishing is automatic once these files are on GitHub; until the package and trusted publisher are configured, publish attempts will fail rather than use a fallback token. After OIDC succeeds, revoke temporary write tokens and consider npm's Require two-factor authentication and disallow tokens setting.

See npm trusted publishers for the provider configuration and supported runners. npm account settings must be configured separately; adding workflow files does not create them.

Preview versions

One successful main push publishes its HEAD, not every historical commit included in that push. The version is:

<base>-next.<workflow-run-number>.<run-attempt>.g<short-sha>

For example, 0.1.0-next.42.1.g7b3f200. If 0.1.0 is already latest, the next base becomes 0.1.1. A higher version staged in the repository is respected; a repository version behind latest fails instead of publishing a downgrade. This short calculation lives in the workflow. The version and lockfile changes occur only in the disposable runner checkout. The ACP agentInfo.version reads the package version, including prerelease suffixes.

Stable releases

Update package.json and package-lock.json to the intended stable version (for example, npm version 0.2.0 --no-git-tag-version), review and merge that change into main, then publish a non-prerelease GitHub Release for tag v0.2.0 at that commit. The workflow files must exist in the tagged commit.

The tag, manifest, and lockfile versions must match. The tagged commit must belong to main's history. The workflow builds a new stable tarball; it does not relabel a prerelease as a stable version. Both channels are passed explicitly to npm publish, so next never accidentally updates latest.

Reruns and failed releases

Publishes are serialized per channel without cancelling a running publish. GitHub can replace an older pending run with a newer one, so rapid pushes do not guarantee a package for every commit. The next job also checks that its SHA is still main's HEAD immediately before publishing; outdated jobs fail with guidance to run the workflow on current main.

A next rerun gets a new attempt number. Stable versions are immutable: if a publish may have succeeded before the job failed, inspect npm before retrying. There is no automatic tarball recovery or dist-tag repair. Do not republish old stable releases to roll latest backward; publish a new version when needed. Registry lookup errors other than HTTP 404 stop preview version calculation.

Design

See DESIGN.md.

About

Use Jev typed decisions from any ACP (Agent Client Protocol) client or IDE

Topics

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages