Skip to content
chenyongssssPublic

About

No description, website, or topics provided.

Resources

Contributing

Security policy

Stars

99 stars

Watchers

0 watching

Forks

Repository files navigation

RevAgent

Evidence-grounded manuscript revision, from reviewer comment to rebuttal

Local-first · Traceable by design · Human-gated

简体中文 · Quick Start · Codex / Claude Code · How It Works · Evaluation

Python Status Tests License Privacy

RevAgent turns reviewer comments into verified manuscript revisions and a consistent rebuttal

Give RevAgent a LaTeX manuscript and reviewer comments. It turns each request into a traceable task, proposes reviewable edits, verifies that rebuttal claims match the manuscript, and keeps the author in control of every consequential decision.

RevAgent is a local-first Python CLI for the revision stage of scientific publishing, with initial support focused on computational mathematics and neighboring computational sciences.

An LLM may interpret comments and draft text, but it is optional. Hashing, source anchoring, diffs, provenance, consistency checks, and approval gates are deterministic and run locally. RevAgent can also be operated through Codex or Claude Code without giving either agent authority to approve scientific claims or apply edits silently.

⚡ TL;DR

reviewer request  ↔  author decision  ↔  manuscript change  ↔  rebuttal claim

Most revision failures occur when one of these links breaks: a comment is missed, a change is not actually applied, evidence becomes stale, or the rebuttal promises more than the manuscript contains. RevAgent makes the links explicit and blocks the workflow when they cannot be verified.

What you need What RevAgent provides
No missed reviewer requests Atomic request extraction and coverage tracking
Safe manuscript changes Anchored candidates, previews, explicit approval, and backups
Defensible scientific claims Proof and experiment obligations tied to current evidence
A consistent rebuttal Point-by-point responses linked to actual manuscript diffs
A clear handoff Local dashboards, blockers, provenance, and readiness reports

🔄 How It Works

flowchart LR
    A[Reviewer comments] --> B[Atomic requests]
    B --> C[Source locations and obligations]
    C --> D[Candidate edits and evidence tasks]
    D --> E{Author approval}
    E -->|revise or reject| D
    E -->|approve| F[Apply with backup]
    F --> G[Diff and evidence verification]
    G --> H[Point-by-point rebuttal]
    H --> I[Consistency and readiness gates]
Loading

Three layers, one responsibility boundary

Layer Responsibility
Optional semantic layer An LLM interprets comments, locates relevant passages, proposes edits, and drafts responses.
Deterministic assurance layer RevAgent hashes inputs, binds source locations, computes diffs, validates schemas, checks coverage, and rejects stale or unsupported artifacts.
Human decision layer The author or a domain expert approves scientific claims, proofs, experiments, final edits, and submission.

The model proposes. RevAgent traces and verifies. The author decides.

🚀 Quick Start

1. Install

git clone https://github.com/chenyongssss/revagent.git
cd revagent
python -m venv .venv
python -m pip install -e .

Activate the environment with .venv\Scripts\Activate.ps1 on Windows or source .venv/bin/activate on macOS/Linux.

2. Initialize a revision workspace

Prepare a LaTeX source tree such as manuscript/ and a reviewer-comments file, then run:

revagent init --journal siam --tex-root manuscript --main-tex paper.tex
revagent revision-run --comments reviewer_comments.tex
revagent revision-consistency

3. Review, approve, and validate

Inspect the generated candidates and approve only the changes you accept. Then:

revagent revision-apply
revagent cockpit --lang en
revagent validate

RevAgent never silently applies an unapproved candidate. ready_for_author_submission means that the local workflow gates passed; it is not a journal decision or a certification of scientific correctness.

🤖 Use with Codex or Claude Code

Most RevAgent users can keep working inside Codex or Claude Code. The coding agent reads the workspace, runs safe RevAgent commands, and drafts changes; RevAgent binds those drafts to LaTeX locations, evidence, hashes, and provenance. Approval and application remain explicit author actions.

1. Open the repository in your agent

Start codex or claude from the repository root, then paste this prompt:

Read .revagent/agent_report.md and plan.md. Continue the revision workflow using safe RevAgent commands. Analyze reviewer requests, propose candidate manuscript edits, and draft point-by-point responses. Never approve or apply an edit. Stop whenever author judgment, scientific validation, or permission is required, and report the exact next command for the author.

2. Let the agent inspect and draft

The agent can use the following safe, non-approval workflow:

revagent agent-status
revagent review-analysis R001
revagent propose

Replace R001 with the review item you want to inspect. At this stage, the agent may analyze, plan, and propose, but it must not run approve, revision-apply, or make scientific decisions on the author's behalf.

3. Review and approve as the author

Inspect each candidate yourself. Approval is a separate, deliberate author action:

revagent inspect C001
revagent approve C001
revagent revision-apply

Replace C001 with the candidate you have reviewed. For high-risk proof, experiment, or scientific-claim changes, complete the relevant evidence and expert-review gates before approval.

4. Verify the finished revision

revagent revision-consistency
revagent validate

The division of responsibility is simple: the coding agent drafts, RevAgent verifies and blocks stale changes, and the author retains scientific authority.

RevAgent can also generate a backend-specific workflow prompt. Preview it before launching either integration:

revagent run --backend codex --goal "continue the revision workflow" --dry-run
revagent run --backend claude --goal "continue the revision workflow" --dry-run

Remove --dry-run only after reviewing the generated prompt. Both adapters preserve the same approval and validation gates.

📦 What You Get

.revagent/
├── review_comment_atoms.json   # normalized reviewer requests
├── revision_tasks.json         # actionable revision plan
├── candidate_edits.json        # reviewable edit candidates
├── response_trace.json         # request → edit → evidence → response
├── revision_consistency.json   # cross-artifact consistency checks
├── rebuttal_draft.md           # point-by-point response draft
└── revision_readiness.json     # blockers and readiness state

The local cockpit turns these artifacts into a compact author-facing view of requests, risks, evidence status, blockers, and pending decisions.

📊 Evaluation

Evidence source Cases Current status
Private computational-mathematics revision histories 3 Complete version chains; only redacted metadata and aggregate hashes are reported
Public eLife revision histories 5 Complete manuscript-version, review, and author-response chains
Public F1000 records 3 Legacy review-only, agent-coded cases

Across the eight public proxy cases, the current release reports 23 adjudicated findings with 100% evidence-excerpt coverage and 100% provenance completeness. These are agent-coded silver metrics, not estimates of human-expert accuracy.

See the evaluation release, community data governance, and release notes.

🎯 Journal and Domain Support

RevAgent ships profiles and reviewer packs for workflows common to SISC, SINUM, Mathematics of Computation, IMA Journal of Numerical Analysis, Journal of Computational Physics, and Numerische Mathematik. These names describe workflow targets and do not imply endorsement by any journal.

🛡️ Safety Boundary

Important

RevAgent is an alpha author-assistance system. It does not certify proofs, convergence, stability, experiments, novelty, response facts, or a final PDF, and it does not submit manuscripts autonomously. Use it in supervised or shadow mode until independent human-expert calibration is complete.

Private manuscript material stays local. Cases/, .revagent/, caches, credentials, and generated working artifacts are excluded from the release package.

📚 Documentation

📄 License

RevAgent is released under the MIT License. Public evaluation records retain their original attribution and per-record license metadata.

About

No description, website, or topics provided.

Resources

Contributing

Security policy

Stars

99 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages