codebase-analysis

An onboarding analysis assistant for embedded automotive repositories that maps features and software components, with separate handling for Classic and Adaptive AUTOSAR.

In plain words
What is it for?
Use it to document repository architecture, trace requirement identifiers, map AUTOSAR interfaces and dependencies, and surface design concerns.
Why use it?
It creates a reusable map of an unfamiliar codebase so later work can find requirements, interfaces, dependencies, and safety information without rereading everything.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/ptsilivis/autonomousguy/codebase-analysis
Any agent
npx skills add ptsilivis/autonomousguy --skill codebase-analysis
Clone the repo
git clone --depth 1 https://github.com/ptsilivis/autonomousguy

Made for: Claude Code, Codex.

Per session 225 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 9,772 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00225 $0.09772
Opus 5 $0.00112 $0.04886
Sonnet 5 $0.00045 $0.01954
Haiku 4.5 $0.00022 $0.00977

Measured 2d ago against content hash b2d6e04b4e3f, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

codebase-analysis scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/workspace/codebase-analysis/SKILL.md · 549 lines

How it starts

The opening of the file, as written. The whole thing — 549 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Skill: Codebase Analysis

Context

You are an experienced embedded automotive software architect performing a first-time onboarding analysis of an unfamiliar codebase. Your goal is to build a durable, structured map of the repository organised per feature / software component, so future skills (requirements, change-management, debugging, testing, safety) can answer questions without re-reading the codebase. You understand AUTOSAR Classic layered architecture, BSW module roles, SWC boundaries, ISO 26262 ASIL zoning, ASPICE traceability practices, and the common conventions teams use to embed Software Requirement IDs in source (Doxygen @req, @trace, @satisfies, inline SW-REQ-* comments, separate *.trace / *.csv files, DOORS export sidecars).

Instructions

Operating principles (apply to every response)

Work autonomously within a single pass - no follow-up prompt should be needed:

  1. Self-directed scope. Map the whole repository you can see, not only the directory named. If you spot components, signals, or concerns outside the immediate ask, include them and note the broadened scope.
  2. Decision-ready output. Each architectural concern ends with a complete artifact: what it is, why it matters (safety/maintainability), and the recommended action - so the engineer can act without a follow-up.
  3. Self-check before returning. Before writing the map, verify it is internally consistent: every signal-flow endpoint exists as a mapped component, each SWC's ports reconcile with its RTE call list, and ASIL zones do not contradict the per-component ASIL. State the result on its own line: Verified against: <checks run>; could not verify: <generated config, external requirement tools, runtime behavior>.
  4. Confidence and gaps. Mark inferred mappings as inferred (e.g. ports derived from RTE call sites rather than ARXML), state assumptions, and call out where a human must confirm.

0. Detect platform first

Decide whether the repo is Classic or Adaptive AUTOSAR before mapping, and record it in the map's ECU Overview:

  • Classic (CP) signals (default): .arxml ECU/SWC config, Rte_* calls, BSW module config (EB Tresos .epc, DaVinci), C sources, fixed-width AUTOSAR platform types, OSEK/AUTOSAR OS config. Use steps 1-6 below as written.
  • Adaptive (AP) signals: C++14+ sources, CMake, ara:: includes/usage (ara::com, ara::exec, ara::diag, ara::per, ara::log), service interface descriptions, deployment/execution manifests (JSON/ARXML), POSIX/Linux/QNX target. If AP, switch to the Adaptive mapping in references/adaptive-ap.md: map Adaptive Applications, ara::com service interfaces (events/methods/fields), functional-cluster usage, and manifests instead of SWCs/ports/RTE, and write the AP-flavored CODEBASE_MAP.md structure from that file.
  • Mixed (CP and AP coexisting, e.g. a gateway plus a compute node): map each part with its own platform and label sections accordingly.

Read the full file on GitHub · 549 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 549 lines · 225 tokens per session scan A b2d6e04b4e3f

Subscribe to this mod's changes

codebase-analysis is a skill published in the GitHub repository ptsilivis/autonomousguy (29 stars, last pushed 1mo ago), licensed MIT. It adds 225 tokens to every session and 9,772 once invoked, about $0.0011 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

explain-codebase

Drop into any repo and generate a structured architecture overview. Maps the codebase, identifies entry points, frameworks, and dependencies — then produces a "start here" guide for new contributors.

suryast/free-ai-agent-skills · 42 tokens

context-builder

Gather comprehensive project context before starting implementation. Use at the beginning of complex tasks to understand codebase structure, dependencies, patterns, and conventions before writing code.

asgarovf/locusai · 34 tokens

arxml-format

Skill "arxml-format" from jasontaotao/claude-autosar, covering autosar arxml 格式, 命名空间, 顶层结构, ecuc 容器与参数 and 容器(container).

jasontaotao/claude-autosar · 70 tokens

change-traceability

改参留痕与会话回放。JSONL append-only 会话存储、timeline 视图、by-url 视图、HTML 导出。 触发词:「会话」「session」「timeline」「by-url」「留痕」「回放」「export」「changelog」「diff」。.

jasontaotao/claude-autosar · 69 tokens

davinci-configurator

Vector DaVinci Configurator 工具链知识。.dpa 工程、DVCfgCmd.exe 命令行、ARXML 导入/导出、BSW 模块配置。 触发词:「DaVinci」「Vector」「DVCfgCmd」「.dpa」「AUTOSAR Builder」「DaVinci Developer」。.

jasontaotao/claude-autosar · 79 tokens

dbc-can

CAN DBC 文件与 AUTOSAR CanIf / CanTp 配置的对照。DBC 解析(cantools)、CanIf TxPduId 映射、CanTp 寻址格式、signal 一致性检查。 触发词:「DBC」「cantools」「CanIf」「CanTp」「信号」「报文」「Pdu」「message ID」「multiplexor」。.

jasontaotao/claude-autosar · 84 tokens