AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified Apache-2.0 Self-run

Infrastructure Reference

skill-docxology-template-reference · by docxology

Bibliographic-reference utilities for research projects. Read, write, and convert BibTeX entries that match the syntax/semantics of projects/templates/template_code_project/manuscript/references.bib (consumed by Pandoc with --natbib during PDF render -- see infrastructure/rendering/_pdf_combined_pandoc.py). Exposes the `citation` submodule (BibTeX I/O + Paper→BibEntry conversion) and the `verific…

No reviews yet
0 installs
9 views
0.0% view→install

Install

$ agentstack add skill-docxology-template-reference

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-docxology-template-reference)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
1mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Infrastructure Reference? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Reference Module

Bibliographic-reference workflows for the template's two-layer architecture. Output is byte-compatible with the existing `projects/templates/template_code_project/manuscript/references.bib` format and round-trips through the parser without semantic loss.

citation — BibTeX read/write/convert

from infrastructure.reference.citation import (
    BibEntry, BibDatabase,
    parse_bibfile, parse_bibtex, BibParseError,
    render_entry, render_database, render_entries, write_bibfile,
    paper_to_bibentry, generate_citation_key,
    escape_latex, unescape_latex,
)

Read & validate an existing .bib

db = parse_bibfile("projects/templates/template_code_project/manuscript/references.bib")
print(len(db), "entries")
boyd = db.find("boyd2004convex")
assert boyd.entry_type == "article"
assert boyd.get("author") == "Boyd, Stephen and Vandenberghe, Lieven"

Build entries programmatically

from collections import OrderedDict
entry = BibEntry(
    entry_type="article",
    citation_key="smith2024example",
    fields=OrderedDict([
        ("title", "An Example Paper"),
        ("author", "Smith, Alice and Jones, Bob"),
        ("journal", "Cambridge UP"),
        ("year", "2024"),
        ("pages", "1-10"),  # auto-normalised to "1--10"
        ("doi", "10.1234/example"),
    ]),
)
print(render_entry(entry))

Output (matches the exemplar exactly):

@article{smith2024example,
  title={An Example Paper},
  author={Smith, Alice and Jones, Bob},
  journal={Cambridge UP},
  year={2024},
  pages={1--10},
  doi={10.1234/example}
}

Convert a literature search result to BibTeX

from infrastructure.search.literature import LiteratureClient, SearchQuery, ArxivBackend
from infrastructure.reference.citation import paper_to_bibentry, render_database
from infrastructure.reference.citation.models import BibDatabase

result = LiteratureClient([ArxivBackend()]).search(SearchQuery(text="adam optimizer"))
db = BibDatabase()
for paper in result.papers:
    db.add(paper_to_bibentry(paper))
write_bibfile("output/references.bib", db)

Validate / format from the CLI

# Round-trip-parse a .bib file.
uv run python -m infrastructure.reference.citation.cli validate \
    projects/templates/template_code_project/manuscript/references.bib

# Re-emit a .bib in canonical format (overwrites in place).
uv run python -m infrastructure.reference.citation.cli format path/to/refs.bib

# Convert a JSON file of literature-search Paper records into BibTeX.
uv run python -m infrastructure.reference.citation.cli convert \
    output/papers.json output/references.bib

verification — reference-existence anti-hallucination gate

Resolves each cited reference against Crossref → OpenAlex (DOI), arXiv (id), or Crossref title search, and classifies it ok / mismatch / fabricated / unverifiable / unchecked / anachronism. Offline-first (consults only the persistent SQLite cache unless allow_network=True); reports unchecked on an offline cache miss so a skipped check never reads as clean.

from infrastructure.reference.verification import (
    ReferenceResolver, ResolutionCache, verify_bibfile, verify_database, verify_entry,
    VerificationStatus, VerificationReport, ReferenceVerdict, BLOCKING_STATUSES,
)

resolver = ReferenceResolver(cache=ResolutionCache("cache.db"), allow_network=True)
report = verify_bibfile("references.bib", resolver, as_of_year=2026)
print(report.summary_line())
assert not report.has_blocking  # no fabricated / mismatch / anachronism
# Offline (cache-only, CI-safe) vs live resolution; gate on blocking verdicts.
uv run python -m infrastructure.reference.verification verify references.bib
uv run python -m infrastructure.reference.verification verify references.bib --live --as-of-year 2026 --fail-on-issues
uv run python -m infrastructure.reference.verification cache-clear

See [verification/SKILL.md](verification/SKILL.md) for the full descriptor.

Format Guarantees

  • 2-space indent on every field line.
  • Trailing comma after every field except the last.
  • pages={N--M} (BibTeX em-dash) regardless of input form (-, , ).
  • Author normalisation around and .
  • Verbatim fields (year, volume, number, month, edition, isbn,

issn, doi, url) are emitted without LaTeX escaping.

  • Unicode is preserved (Pandoc / XeLaTeX handle it natively, matching the

exemplar's convention).

  • book / phdthesis / techreport / misc entries never receive a

spurious journal= field even when their source declared a venue.

Related Modules

  • [infrastructure.search.literature](../search/literature/SKILL.md) —

discovery side of the literature workflow.

  • [infrastructure.publishing.citations](../publishing/SKILL.md) — citation

string generation (APA / MLA) for human-facing markdown sections.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.