# Academic Figure Architecture Extractor & Analyzer

> Architecture diagram analysis for academic PDFs or images — structure, components, and redraw parameters for prompt skills. Use when the user wants 架构图分析, extract figures from PDF, or architecture diagram breakdown.

- **Type:** Skill
- **Install:** `agentstack add skill-azhi-ss-academic-figure-skills-academic-figure-architecture-extractor`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [Azhi-ss](https://agentstack.voostack.com/s/azhi-ss)
- **Installs:** 0
- **Category:** [Content & Media](https://agentstack.voostack.com/c/content-and-media)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [Azhi-ss](https://github.com/Azhi-ss)
- **Source:** https://github.com/Azhi-ss/academic-figure-skills/tree/main/academic-figure-architecture-extractor
- **Website:** https://www.skills.sh/azhi-ss/academic-figure-skills

## Install

```sh
agentstack add skill-azhi-ss-academic-figure-skills-academic-figure-architecture-extractor
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Academic Figure Architecture Extractor & Analyzer

Turn paper PDFs or existing architecture images into a structured **架构图分析结果** that handoffs cleanly to color-expert and prompt skills.

Palettes: → `../docs/palettes.md` (names only)  
Missing info: → `../docs/missing-info-policy.md`  
Extractor: → `scripts/extract_pdf_figures.py`

## Honest scope

- Prefer user-supplied figure images when available.
- PDF extraction is a **real local helper** (pdfimages / PyMuPDF / optional pdftoppm), not a trained detector.
- Size filter is heuristic only; architecture vs photo/table is **agent judgment**.
- Palette: recommend **names** from `docs/palettes.md`; hex via color-expert when needed.

## Input Contract

- Prefer: PDF path(s), figure images, domain, venue
- Minimum: one PDF **or** one architecture image
- Missing: analyze what exists; list blocked steps

## Output Contract — 架构图分析结果

- inventory (path/page, size, keep/drop reason)
- per-kept-figure structure (components, hierarchy, flow, type)
- recommended palette **names**
- redraw parameters for `academic-figure-prompt`

## Steps

### Step 1: Obtain images

**Images given** → index paths.

**PDF given** → run the helper (from skill dir or repo root):

```bash
python3 academic-figure-architecture-extractor/scripts/extract_pdf_figures.py \
  /path/to/paper.pdf -o /tmp/arch-extract/paper
```

Useful flags:

| flag | meaning |
|------|---------|
| `--backend auto\|pdfimages\|pymupdf` | embedded-image backend |
| `--min-side 300` | drop tiny icons (default) |
| `--min-pixels 90000` | drop low-res crops |
| `--pages 4` or `--pages 1-3` or `--pages all` | also rasterize pages via pdftoppm |
| `--dpi 150` | raster DPI |

Read `extract-report.json` in the out dir (`kept` / `dropped` / `tools`).

If both backends missing → ask user for exported figures; do not invent paths.

Done when: each candidate has a path or page reference, or a clear tool blocker is stated.

### Step 2: Filter to architecture-like figures

Start from `kept` (size-ok). Agent reclassifies:

| keep cues | drop cues |
|-----------|-----------|
| boxes + arrows, layered blocks | pure photos, scatter-only, dense tables |
| structured edges / modules | tiny icons already size-dropped |

Unsure → keep + `待确认`.

Done when: each image is keep / drop / uncertain with a one-line reason.

### Step 3: Structure analysis

For each kept figure:

1. components (core vs auxiliary)  
2. hierarchy / dataflow  
3. type: Overall Framework / Network Architecture / Module Detail / Comparison  
4. domain notes  

Done when: every kept figure has type + component list + flow summary.

### Step 4: Palette suggestion + redraw handoff

Map via `docs/palettes.md` (e.g. ≥4-module framework → Nature Blue; module detail → Blue Monochrome; comparison → ML TopConf Deep).

```
图类型: ...
核心组件: ...
配色方案名: ...
布局建议: 16:9 | 3:2 | 4:3
风格: white fill, colored borders, flat vector
标注要求: ...
```

Done when: each kept figure has redraw params + palette names (no hex tables).

## Stop

Stop when the report is delivered, extraction is blocked pending user images, or the user only wanted inventory.

## Source & license

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

- **Author:** [Azhi-ss](https://github.com/Azhi-ss)
- **Source:** [Azhi-ss/academic-figure-skills](https://github.com/Azhi-ss/academic-figure-skills)
- **License:** MIT
- **Homepage:** https://www.skills.sh/azhi-ss/academic-figure-skills

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

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-azhi-ss-academic-figure-skills-academic-figure-architecture-extractor
- Seller: https://agentstack.voostack.com/s/azhi-ss
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
