{
  "_id": "6ace91ccf6f39cd7e29a16fe",
  "Package": "admiralagent",
  "Title": "Spec-Driven ADaM Code Generation with LLM-Translated Layers",
  "Version": "0.1.0.9000",
  "Authors@R": "person(\"Jaime\", \"Yan\", role = c(\"aut\", \"cre\"), email = \"yanmingyunmt@gmail.com\")",
  "Description": "Translates P21-style ADaM specifications into executable\n'admiral' code with validation comments. An LLM (optional, via\n'ellmer') maps each spec variable's free-text derivation onto a\nclosed vocabulary of derivation layers (structured JSON IR); a\ndeterministic compiler renders the IR into\n'admiral'/'metatools' code with 'CHECK' validation comments and\nwrites provenance sidecars. Ships with a zero-dependency\nrule-based classifier as baseline and fallback; the LLM never\nwrites R code directly and all model output is validated\nagainst the closed vocabulary before use.",
  "License": "MIT + file LICENSE",
  "Encoding": "UTF-8",
  "URL": "https://github.com/yanmingyu92/admiralagent",
  "BugReports": "https://github.com/yanmingyu92/admiralagent/issues",
  "VignetteBuilder": "knitr",
  "Config/testthat/edition": "3",
  "Config/roxygen2/version": "8.1.0",
  "Repository": "https://yanmingyu92.r-universe.dev",
  "Date/Publication": "2026-10-13 18:03:57 UTC",
  "RemoteUrl": "https://github.com/yanmingyu92/admiralagent",
  "RemoteRef": "HEAD",
  "RemoteSha": "9e098d396053605068653b138ed0ad196f3f7770",
  "NeedsCompilation": "no",
  "Packaged": {
    "Date": "2026-10-13 19:48:18 UTC",
    "User": "root"
  },
  "Author": "Jaime Yan [aut, cre]",
  "Maintainer": "Jaime Yan <yanmingyunmt@gmail.com>",
  "_user": "yanmingyu92",
  "_type": "src",
  "_file": "admiralagent_0.1.0.9000.tar.gz",
  "_fileid": "https://r2.ropensci.org/de8774b294cc771ba7cd1e95100dfa02fd2d0d800507fd5c9cdd826b986bde84",
  "_filesize": 398125,
  "_sha256": "de8774b294cc771ba7cd1e95100dfa02fd2d0d800507fd5c9cdd826b986bde84",
  "_expires": "2027-01-21T20:17:13.000Z",
  "_created": "2026-10-13T19:48:18.000Z",
  "_published": "2026-10-13T20:17:15.912Z",
  "_buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907",
  "_status": "success",
  "_host": "GitHub-Actions",
  "_jobs": [
    {
      "job": 115504933748,
      "time": 202,
      "config": "linux-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "11844302793"
    },
    {
      "job": 115504934005,
      "time": 178,
      "config": "linux-release-x86_64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "11845185926"
    },
    {
      "job": 115504933644,
      "time": 158,
      "config": "macos-oldrel-arm64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "11845670629"
    },
    {
      "job": 115504933810,
      "time": 165,
      "config": "macos-release-arm64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "11846145989"
    },
    {
      "job": 115503255296,
      "time": 219,
      "config": "source",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "11844455876"
    },
    {
      "job": 115504933967,
      "time": 103,
      "config": "wasm-release",
      "r": "4.6.0",
      "check": "OK",
      "artifact": "11844022707"
    },
    {
      "job": 115504933809,
      "time": 181,
      "config": "windows-devel-x86_64",
      "r": "4.7.0",
      "check": "OK",
      "artifact": "11844851269"
    },
    {
      "job": 115504933865,
      "time": 170,
      "config": "windows-oldrel-x86_64",
      "r": "4.5.3",
      "check": "OK",
      "artifact": "11844591330"
    },
    {
      "job": 115504933989,
      "time": 156,
      "config": "windows-release-x86_64",
      "r": "4.6.1",
      "check": "OK",
      "artifact": "11844761052"
    }
  ],
  "_upstream": "https://github.com/yanmingyu92/admiralagent",
  "_commit": {
    "id": "9e098d396053605068653b138ed0ad196f3f7770",
    "author": "Jaime Yan <yanmingyu92@users.noreply.github.com>",
    "committer": "Jaime Yan <yanmingyu92@users.noreply.github.com>",
    "message": "ci: ASCII-only R code; corpus-independent acceptance test thresholds\n",
    "time": 1791914637
  },
  "_maintainer": {
    "name": "Jaime Yan",
    "email": "yanmingyunmt@gmail.com",
    "login": "yanmingyu",
    "description": "",
    "uuid": 25801487
  },
  "_distro": "resolute",
  "_registered": true,
  "_dependencies": [
    {
      "package": "R",
      "version": ">= 4.1",
      "role": "Depends"
    },
    {
      "package": "glue",
      "role": "Imports"
    },
    {
      "package": "jsonlite",
      "role": "Imports"
    },
    {
      "package": "digest",
      "role": "Imports"
    },
    {
      "package": "stats",
      "role": "Imports"
    },
    {
      "package": "utils",
      "role": "Imports"
    },
    {
      "package": "xml2",
      "role": "Suggests"
    },
    {
      "package": "ellmer",
      "role": "Suggests"
    },
    {
      "package": "metacore",
      "role": "Suggests"
    },
    {
      "package": "admiral",
      "role": "Suggests"
    },
    {
      "package": "metatools",
      "role": "Suggests"
    },
    {
      "package": "readxl",
      "role": "Suggests"
    },
    {
      "package": "testthat",
      "version": ">= 3.0.0",
      "role": "Suggests"
    },
    {
      "package": "rlang",
      "role": "Suggests"
    },
    {
      "package": "tibble",
      "role": "Suggests"
    },
    {
      "package": "knitr",
      "role": "Suggests"
    },
    {
      "package": "rmarkdown",
      "role": "Suggests"
    },
    {
      "package": "dplyr",
      "role": "Suggests"
    },
    {
      "package": "haven",
      "role": "Suggests"
    },
    {
      "package": "pharmaversesdtm",
      "role": "Suggests"
    },
    {
      "package": "pharmaverseadam",
      "role": "Suggests"
    }
  ],
  "_owner": "yanmingyu92",
  "_selfowned": true,
  "_usedby": 0,
  "_updates": [
    {
      "week": "2026-40",
      "n": 19
    },
    {
      "week": "2026-41",
      "n": 5
    },
    {
      "week": "2026-42",
      "n": 5
    }
  ],
  "_tags": [],
  "_stars": 2,
  "_contributors": [
    {
      "user": "yanmingyu92",
      "count": 29,
      "uuid": 159562441
    }
  ],
  "_userbio": {
    "uuid": 159562441,
    "type": "user",
    "name": "Mingyu Yan",
    "followers": 4
  },
  "_downloads": {
    "count": 0,
    "source": "https://cranlogs.r-pkg.org/downloads/total/last-month/admiralagent"
  },
  "_devurl": "https://github.com/yanmingyu92/admiralagent",
  "_searchresults": 4,
  "_rbuild": "4.6.1",
  "_assets": [
    "extra/admiralagent.html",
    "extra/citation.cff",
    "extra/citation.html",
    "extra/citation.json",
    "extra/citation.txt",
    "extra/contents.json",
    "extra/manual.pdf",
    "extra/NEWS.html",
    "extra/NEWS.txt",
    "extra/readme.html",
    "extra/readme.md",
    "LICENSE"
  ],
  "_cranurl": false,
  "_exports": [
    "aa_layers",
    "accept_model",
    "agreement_overstatement",
    "artifact_hash",
    "build_context",
    "build_system_prompt",
    "check_admiral_compat",
    "classify_variables",
    "classify_variables_dual",
    "classify_variables_llm",
    "codelist_from_data",
    "dataset_json_meta",
    "dual_disagreements",
    "evals_accuracy",
    "execute_ir",
    "ir_dependency_report",
    "layer_docs",
    "layer_names",
    "load_evals",
    "mcp_handle_request",
    "mcp_serve",
    "mcp_tool_specs",
    "mock_metacore",
    "mock_spec_adsl",
    "new_step",
    "new_variable_ir",
    "read_artifact",
    "read_dataset_json",
    "read_define",
    "read_spec",
    "read_spec_df",
    "render_program",
    "render_variable",
    "routing_plan",
    "run_agreement",
    "run_evals",
    "run_validation",
    "spec_variables",
    "validate_ir",
    "write_artifact",
    "write_program_artifact"
  ],
  "_help": [
    {
      "page": "aa_layers",
      "title": "Layer registry",
      "topics": [
        "aa_layers"
      ]
    },
    {
      "page": "accept_model",
      "title": "Model acceptance gate",
      "topics": [
        "accept_model"
      ]
    },
    {
      "page": "agreement_overstatement",
      "title": "How much an args-blind label overstates agreement",
      "topics": [
        "agreement_overstatement"
      ]
    },
    {
      "page": "artifact_hash",
      "title": "Artifact hash",
      "topics": [
        "artifact_hash"
      ]
    },
    {
      "page": "build_context",
      "title": "Build LLM context",
      "topics": [
        "build_context"
      ]
    },
    {
      "page": "build_system_prompt",
      "title": "Build system prompt",
      "topics": [
        "build_system_prompt"
      ]
    },
    {
      "page": "check_admiral_compat",
      "title": "admiral compatibility check",
      "topics": [
        "check_admiral_compat"
      ]
    },
    {
      "page": "classify_variables",
      "title": "Classify spec variables",
      "topics": [
        "classify_variables"
      ]
    },
    {
      "page": "classify_variables_dual",
      "title": "Dual-backend consensus classification",
      "topics": [
        "classify_variables_dual"
      ]
    },
    {
      "page": "classify_variables_llm",
      "title": "Classify spec variables via an LLM chat backend",
      "topics": [
        "classify_variables_llm"
      ]
    },
    {
      "page": "codelist_from_data",
      "title": "Build a codelist data.frame from observed data values",
      "topics": [
        "codelist_from_data"
      ]
    },
    {
      "page": "dataset_json_meta",
      "title": "Dataset-JSON header metadata",
      "topics": [
        "dataset_json_meta"
      ]
    },
    {
      "page": "dual_disagreements",
      "title": "Dual-backend disagreements",
      "topics": [
        "dual_disagreements"
      ]
    },
    {
      "page": "evals_accuracy",
      "title": "Accuracy of an eval run",
      "topics": [
        "evals_accuracy"
      ]
    },
    {
      "page": "execute_ir",
      "title": "Execute a Layer IR against source datasets",
      "topics": [
        "execute_ir"
      ]
    },
    {
      "page": "ir_dependency_report",
      "title": "IR dependency report",
      "topics": [
        "ir_dependency_report"
      ]
    },
    {
      "page": "layer_docs",
      "title": "Layer documentation cards",
      "topics": [
        "layer_docs"
      ]
    },
    {
      "page": "layer_names",
      "title": "Layer names",
      "topics": [
        "layer_names"
      ]
    },
    {
      "page": "load_evals",
      "title": "Load the spec-to-IR classification eval corpus",
      "topics": [
        "load_evals"
      ]
    },
    {
      "page": "mcp_handle_request",
      "title": "Handle one MCP / JSON-RPC 2.0 request",
      "topics": [
        "mcp_handle_request"
      ]
    },
    {
      "page": "mcp_serve",
      "title": "Run the admiralagent MCP stdio server",
      "topics": [
        "mcp_serve"
      ]
    },
    {
      "page": "mcp_tool_specs",
      "title": "Tool specifications for the admiralagent MCP server",
      "topics": [
        "mcp_tool_specs"
      ]
    },
    {
      "page": "mock_metacore",
      "title": "Build a minimal executable metacore object from a spec data frame",
      "topics": [
        "mock_metacore"
      ]
    },
    {
      "page": "mock_spec_adsl",
      "title": "Mock ADSL spec",
      "topics": [
        "mock_spec_adsl"
      ]
    },
    {
      "page": "new_step",
      "title": "New layer step",
      "topics": [
        "new_step"
      ]
    },
    {
      "page": "new_variable_ir",
      "title": "New variable IR",
      "topics": [
        "new_variable_ir"
      ]
    },
    {
      "page": "print.aa_agreement",
      "title": "Print an agreement report",
      "topics": [
        "print.aa_agreement"
      ]
    },
    {
      "page": "print.aa_model_acceptance",
      "title": "Print a model acceptance report",
      "topics": [
        "print.aa_model_acceptance"
      ]
    },
    {
      "page": "read_artifact",
      "title": "Read artifact",
      "topics": [
        "read_artifact"
      ]
    },
    {
      "page": "read_dataset_json",
      "title": "Read a Dataset-JSON file",
      "topics": [
        "read_dataset_json"
      ]
    },
    {
      "page": "read_define",
      "title": "Read define.xml",
      "topics": [
        "read_define"
      ]
    },
    {
      "page": "read_spec",
      "title": "Read spec workbook",
      "topics": [
        "read_spec"
      ]
    },
    {
      "page": "read_spec_df",
      "title": "Normalize spec data frame",
      "topics": [
        "read_spec_df"
      ]
    },
    {
      "page": "render_program",
      "title": "Render program",
      "topics": [
        "render_program"
      ]
    },
    {
      "page": "render_variable",
      "title": "Render a variable",
      "topics": [
        "render_variable"
      ]
    },
    {
      "page": "routing_plan",
      "title": "Dependency routing plan",
      "topics": [
        "routing_plan"
      ]
    },
    {
      "page": "run_agreement",
      "title": "Cross-tabulate classification backends at every fingerprint level",
      "topics": [
        "run_agreement"
      ]
    },
    {
      "page": "run_evals",
      "title": "Run the spec-to-IR classification evals",
      "topics": [
        "run_evals"
      ]
    },
    {
      "page": "run_validation",
      "title": "Run validation",
      "topics": [
        "run_validation"
      ]
    },
    {
      "page": "spec_variables",
      "title": "Spec rows for a dataset",
      "topics": [
        "spec_variables"
      ]
    },
    {
      "page": "validate_ir",
      "title": "IR validation gate",
      "topics": [
        "validate_ir"
      ]
    },
    {
      "page": "write_artifact",
      "title": "Write variable artifacts",
      "topics": [
        "write_artifact"
      ]
    },
    {
      "page": "write_program_artifact",
      "title": "Write program artifact",
      "topics": [
        "write_program_artifact"
      ]
    }
  ],
  "_readme": "https://github.com/yanmingyu92/admiralagent/raw/HEAD/README.md",
  "_rundeps": [
    "digest",
    "glue",
    "jsonlite"
  ],
  "_vignettes": [
    {
      "source": "admiralagent.Rmd",
      "filename": "admiralagent.html",
      "title": "admiralagent: Spec-to-ADaM with LLM-Translated Layers",
      "engine": "knitr::rmarkdown",
      "headings": [
        "The idea",
        "Walkthrough on the mock ADSL spec",
        "Accuracy story: rules vs the pilot1 oracle",
        "MCP server: the same gates from any agent",
        "Improvement-loop philosophy"
      ],
      "created": "2026-09-30 14:15:48",
      "modified": "2026-09-30 14:15:48",
      "commits": 1
    }
  ],
  "_score": 3.4771212547196626,
  "_indexed": true,
  "_nocasepkg": "admiralagent",
  "_universes": [
    "yanmingyu92",
    "yanmingyu"
  ],
  "_previous": "0.1.0",
  "_binaries": [
    {
      "r": "4.7.0",
      "os": "linux",
      "version": "0.1.0.9000",
      "date": "2026-10-13T19:50:41.000Z",
      "distro": "resolute",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/a5ca1085bacb8e4664213cf0950bd680e5227b0722c04365226e7b1c87fe97a4",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.6.1",
      "os": "linux",
      "version": "0.1.0.9000",
      "date": "2026-10-13T19:50:30.000Z",
      "distro": "resolute",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/99a06971d397478600cfa51fc3c0d0de5d0e22b7c858de59e2c08106edc0c00b",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.5.3",
      "os": "mac",
      "version": "0.1.0.9000",
      "date": "2026-10-13T20:05:22.000Z",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/04e30468785ba2e60039149c9e1866bbcfc79fa233297836b9d9634ffdfc7f7b",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.6.1",
      "os": "mac",
      "version": "0.1.0.9000",
      "date": "2026-10-13T20:15:36.000Z",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/2b5f3977d86bf13c6ee23190ca34b3bff380021274cc1fb87f6a96eec0660945",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.6.0",
      "os": "wasm",
      "version": "0.1.0.9000",
      "date": "2026-10-13T19:50:25.000Z",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/173afc5a2ca8ca4f9a88c4c59e706f293f910c68094350a484d9f23fcf4fd756",
      "status": "success",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.7.0",
      "os": "win",
      "version": "0.1.0.9000",
      "date": "2026-10-13T19:49:45.000Z",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/d673befa5da9ec3893c17bf08460c0837c60c48845fbdbf45c427f6a8cc3a508",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.5.3",
      "os": "win",
      "version": "0.1.0.9000",
      "date": "2026-10-13T19:49:40.000Z",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/848ecc308a737fefb0e4837944b746183fd03abb3c82f6b574fe05f6c4b1fbe1",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    },
    {
      "r": "4.6.1",
      "os": "win",
      "version": "0.1.0.9000",
      "date": "2026-10-13T19:49:53.000Z",
      "commit": "9e098d396053605068653b138ed0ad196f3f7770",
      "fileid": "https://r2.ropensci.org/26333d601049742838962a7ee42dde579bd2743cedf199b41e328addfa2e3470",
      "status": "success",
      "check": "OK",
      "buildurl": "https://github.com/r-universe/yanmingyu92/actions/runs/38457265907"
    }
  ]
}