Self-hosted service
QJHWC/PaperForge avatar
QJHWC/PaperForge

PaperForge: a claim in the paper has to name the evidence behind it

End-to-end AI-powered academic paper writing system β€” from idea generation and literature search to experiment execution, result backfill, and LaTeX paper compilation. Supports multi-LLM routing, SSH remote training, incremental sync, and anti-AI-detection writing style.

644 stars97 forksPythonLicense varies

At a glance

What is it?
PaperForge v3 is an evidence-centred research system in Python that runs research, experiment, code, compute, analysis, visualisation, paper, reviewer and release agents on one runtime, keeps claims and runs in a SQLite scientific memory, and refuses to mark a workflow complete until the claim gate, the PDF, the secret scan and the release manifest all pass.
Who is it for?
PaperForge fits a group writing papers where reproducibility is contested rather than assumed, because the claim gate, the artifact hashes and the verifiable release step turn an assertion into something with a recorded source. Four cautions.
Can I use it commercially?
Check first. The repository uses a licence we do not classify automatically, so read its LICENSE file before any commercial use.
Is it still maintained?
Yes. The repository last received commits 9 days ago.
What is it written in?
Mainly Python, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on November 25, 2026, and from our analysis. They are not legal advice.

From daily snapshots

Star history

  • QJHWC/PaperForge644 β˜… Β· +15
Star history
Repository2026-09-112026-11-25
QJHWC/PaperForge629644

15 Stars in the last 75 days, measured from the daily GitHub snapshot. Compare with other projects

Editorial analysis

One SQLite file holds the workflow, the claims and the artifacts

The persistence model is easy to inspect because each workspace gets its own state directory with a fixed layout:

text
<workspace>/
β”œβ”€β”€ .paperforge/
β”‚   β”œβ”€β”€ paperforge.db
β”‚   β”œβ”€β”€ runtime/
β”‚   β”œβ”€β”€ publication/
β”‚   └── release_manifest.json
β”œβ”€β”€ artifacts/
β”œβ”€β”€ dist/
β”œβ”€β”€ main.tex
└── references.bib

`.paperforge/paperforge.db` is the one file that matters. It stores workflows, events, approvals, sources, evidence, claims, experiments, artifacts and review results, so a run leaves a trail rather than a log file. The write discipline is stated in three words: version numbers, idempotency keys and transactions. That combination is what makes the third entry in that layout meaningful, because `paperforge resume --workspace workspace/my-paper` recovers an interrupted job rather than starting a duplicate one. The `release_manifest.json` beside the database is the other file to know about, since the release verifier reads it and the publish gate is checked against it. Everything else in the directory is conventional: `main.tex` and `references.bib` are your sources, `artifacts/` holds generated files, and `dist/` holds the built output.

A claim in the paper has to name the evidence behind it

The central idea is a database table rather than a writing rule. Any claim the paper makes in public has to carry a `claim_id` that links it to evidence: source code, literature, a run result, an experiment result, or a licence record. That is the difference from an assistant that cites loosely, because the link is structural and lives in the same SQLite file as the runs. Nine agents share one runtime in v3, covering research, experiment, code, compute, analysis, visualisation, paper, reviewer and release, which is why the reviewer and the writer are looking at the same evidence rather than at each other's summaries. The release gate is where the idea becomes enforced. A workflow only reaches `COMPLETED` when the claim gate, the PDF, the protected blocks, the page checks, the secret scan and the release manifest have all passed. Publication supports Generic, CVPR, IEEE and Elsevier templates and allows up to three rounds of compile, render, diagnostics and constrained typesetting repair, which is an admission that LaTeX builds fail in ways a language model cannot see.

writing-only refuses at four layers, not one

Execution permission in v3 is three enforced policies, `writing-only`, `research` and `full`, replacing v2's reliance on calling convention and prompt wording. The `writing-only` profile is the one to understand, because it is the mode most people will actually use and it refuses in four places: the policy layer, the tool registration layer, the command layer and the context layer. Concretely it refuses training, inference and experiment commands; SSH, containers and remote compute; weight files with extensions like `.pt`, `.pth`, `.ckpt` and `.onnx`; experiment data in CSV, NumPy or Parquet form; `run_*` result directories; and executable experiment scripts. The point of refusing at four layers is that a user cannot route around the policy by being clever with a file path or a job manifest. Writing context accepts only `.bib`, `.docx`, `.md`, `.pdf`, `.rst`, `.tex` and `.txt` documents, and a job manifest must live inside the workspace and stay under 1 MiB. `paperforge status` and `paperforge resume` round out the three commands you need for a writing run.

The writing provider is pinned, and config.json cannot change it

This is the part that will surprise anyone who expects model choice to be configuration. The current v3 formal writing path is fixed to the `bailu` provider and the `bailu-turing` model, and the readme explicitly warns against relying on `config.json` to change it, because the current CLI runtime does not inject `provider`, `model` or `generation_profile` from that file into the writing agent. Credentials live elsewhere on purpose: no plaintext keys as command line arguments, and nothing written into the workspace. You create a `credentials.json` holding a `bailu_primary` value, and on macOS and Linux you are expected to restrict it yourself:

bash
chmod 600 ~/.config/paperforge/credentials.json

Windows checks the file ACL instead, and the credentials file must not be exposed to other users. `bailu-turing` speaks an OpenAI-compatible protocol with a default base URL, and a compatibility layer quietly strips the fields that endpoint does not support, namely `reasoning_effort`, `seed`, `n` and `stop`, applying the same rule across the single, batch, review, citation, stream and Aider paths. Setting conflicting `OPENAI_BASE_URL`, `OPENAI_WRITEUP_BASE_URL` and `OPENAI_API_BASE` variables is a hard stop rather than a warning.

preflight has four states and only one of them touches the network

The static check is a single command:

bash
paperforge preflight --workspace .

Adding `--live-provider` turns it into one minimal real request to the provider, which is the only path that reaches the network. The four states are worth memorising because scripts branch on them. `CODE_VERIFIED` means Python and the workspace basics are usable. `EXTERNAL_SERVICE_VERIFIED` means the minimal provider request succeeded. `AUTH_BLOCKED` means there is no key, or the service answered 401 or 403. `FAILED` means an unsupported Python version, an unusable workspace, or a configuration or network error during an explicit live check. Two subtleties are documented and easy to miss. The top-level status of a static preflight reflects only Python and the workspace, while `latex_compiler`, `bibtex` and `pdftoppm` are reported as separate fields, so a machine with no LaTeX can still come back verified. That missing toolchain then fails the corresponding publish gate later rather than the preflight. And `AUTH_BLOCKED` deliberately does not trigger long-text retries or further large generation requests, which is the difference between a failed login and a loop that keeps spending tokens.

Experiments have to pass four gates before they count

v2 organised experiments inside the writing workflow, which is the arrangement that produces results nobody can reconstruct. v3 replaces that with a fixed sequence: proposal, then a static check, then a mini experiment, then the full experiment, with approval required along the way. Everything needed to repeat the run is recorded, including code, configuration, data, weights, metrics and artifact hashes, which is why the weights are stored next to the metrics rather than left in a scratch directory. Compute is abstracted behind one interface covering Local, Docker, SSH, Slurm, Kubernetes and Cloud SSH, so the same experiment definition can move from a laptop to a cluster without a new code path. The SSH path is real rather than aspirational, with `paramiko` among the pinned dependencies of the experiment extra. What the sequence buys you is a record of the attempt that failed, which is usually the artifact a reviewer asks for later.

The container installs dependencies without the dependency metadata

The image is built on `python:3.11-slim-bookworm` and installs the TeX stack by hand, including latexmk, chktex, poppler-utils and a set of texlive packages, then creates a system user and runs as it. Two lines in it deserve attention:

code
RUN python -m pip install --no-deps /opt/paperforge && \
    mkdir -p /workspace && chown -R paperforge:paperforge /workspace /opt/paperforge

USER paperforge
WORKDIR /workspace

ENTRYPOINT ["paperforge"]
CMD ["preflight", "--workspace", "/workspace"]

That install is deliberate, and it is the first thing to check when an image behaves differently from a local virtual environment, because it means the image trusts the requirements file rather than the dependency list in the package metadata. The second is the default command: running the image with no arguments performs a preflight against the workspace rather than doing any work, which makes the container usable as a smoke test before you point it at a paper. Note also that the image is Python 3.11 while the readme tells you to create the virtual environment with 3.12, so the two supported paths are not the same interpreter.

MIT in the package metadata, a non-commercial disclaimer in the readme

The licensing picture is contradictory, and for an academic project that matters. The package metadata declares MIT and names a license file, and a `LICENSE` is present at the root along with `THIRD_PARTY_NOTICES.md` and a `CITATION.cff`. The readme opens with a disclaimer stating the project is for study and research only, must not be used for any commercial purpose, and that the user bears the consequences of anything produced with it. Repository metadata reports no recognised licence at all, which is what an automated scanner sees. If you intend to build a commercial tool on top of this, resolve that before you write code rather than after. The dependency story has the same shape. There are six requirements files alongside the extras, and the default `requirements.txt` pulls in the research and experiment sets, meaning a plain install of that file brings the training stack whether you wanted it or not.

Editorial conclusion

PaperForge fits a group writing papers where reproducibility is contested rather than assumed, because the claim gate, the artifact hashes and the verifiable release step turn an assertion into something with a recorded source. Four cautions. The formal writing path is pinned to one provider and model, and the configuration file that looks like it should change that is explicitly documented as not being injected, so treat model choice as fixed unless you patch it. The project carries a non-commercial-use disclaimer in its readme while the package metadata says MIT, and the repository metadata reports no licence at all, so get that clarified before you build on it. The container installs dependencies without the dependency metadata, so an image built from a stale requirements file will run with whatever was there. And if you only need writing, install the writing extra and skip the PyTorch stack entirely.

Frequently asked questions

What must a claim in a PaperForge paper point to?

A claim_id that links it to evidence held in the SQLite scientific memory, which can be source code, literature, a run result, an experiment result or a licence record. Claims, evidence, runs and artifacts all live in .paperforge/paperforge.db.

What does the writing-only profile in PaperForge refuse?

It refuses at four layers, policy, tool registration, command and context: training, inference and experiment commands, SSH and containers and remote compute, weight files such as .pt and .onnx, experiment data in CSV or Parquet, run_ result directories and executable experiment scripts.

Which AI provider does PaperForge v3 use for formal writing?

The bailu provider with the bailu-turing model, fixed in the current v3 writing path. The readme warns that config.json is not injected into the writing agent, so its provider, model and generation_profile fields will not switch the model.

What does paperforge preflight check?

The static form reports CODE_VERIFIED, AUTH_BLOCKED or FAILED from Python and workspace state alone, with latex_compiler, bibtex and pdftoppm reported as separate fields. Adding --live-provider makes one minimal provider request and can return EXTERNAL_SERVICE_VERIFIED.

What has to pass before a PaperForge workflow reaches COMPLETED?

The claim gate, the PDF, the protected blocks, the page checks, the secret scan and the release manifest. Publication supports Generic, CVPR, IEEE and Elsevier templates with up to three rounds of compile, render, diagnostics and constrained typesetting repair.

Official sources

  1. Issues
  2. QJHWC/PaperForge on GitHub
  3. README
Add this badge to your README

If you maintain this project, the badge below links readers to this analysis and shows its maintenance status from the daily GitHub snapshot. Paste the markdown into your README; add ?metric=license or ?metric=stars to the image URL for a different field.

Add this badge to your README

markdown
[![Hysen Labs](https://hysenlabs.com/badge/qjhwc-paperforge.svg)](https://hysenlabs.com/projects/qjhwc-paperforge)

Star history chart for your README

markdown
[![Star history](https://hysenlabs.com/chart/qjhwc-paperforge.svg)](https://hysenlabs.com/projects/qjhwc-paperforge)

Was this useful?