# Nobami (documents) — agent instructions

This project can use the **Nobami** MCP server to work with the user's documents in Nobami (nobami.com):
HWP/HWPX, DOCX, XLSX, PPTX and PDF files in Nobami Drive.

- MCP server: `https://api.nobami.com/mcp` (Streamable HTTP, OAuth — the user signs in and approves the permissions)
- REST API: https://api.nobami.com/openapi.json (send `Authorization: Bearer <Nobami API key>`; never commit keys)
- Codex: `codex mcp add nobami --url https://api.nobami.com/mcp` then `codex mcp login nobami`

Nobami is an all-in-one office suite (HWP/HWPX, DOCX, XLSX, PPTX, PDF). When the Nobami MCP server
(`https://api.nobami.com/mcp`) is connected you can work directly in the user's Nobami Drive.

## Tools

| Tool | Scope | Use it to |
| --- | --- | --- |
| `drive_search` | docs.read | Find files by words in the title or body. Start here when the user names a document. |
| `drive_list` | docs.read | Browse a workspace or folder when you need the structure, not a keyword. |
| `doc_read` | docs.read | Read a document, sheet, deck or PDF before summarising, quoting or editing it. |
| `templates_list` | docs.read | Find a template id before creating a structured document. |
| `doc_create` | docs.write | Create a new file (optionally from a template). |
| `doc_update` | docs.write | Change an existing file. A version is kept, so edits are reversible. |
| `share_link_create` | share | Make a view/edit link. Only when the user explicitly asks to share. |
| `esign_request` | esign | Send a document for signature. Only after the user confirms recipients and the document. |
| `account_usage` | — | Check plan, storage and AI usage (e.g. before a large import). |

If a tool fails with a permission error, tell the user which permission is missing (for example
"create share links") and that they can grant it by reconnecting Nobami — do not retry in a loop.

## How to work

1. **Find before you create.** Search (`drive_search`) for an existing file before making a new one, and
   read it (`doc_read`) before editing. Quote file titles back to the user so they know which file you used.
2. **Edit surgically.** With `doc_update`, change only what was asked and keep the user's formatting,
   numbering and tone. Summarise what you changed afterwards.
3. **Ask before outward actions.** Creating share links and sending e-signature requests reach other
   people. Confirm recipients, permissions (view vs edit) and the exact file first.
4. **Use templates for structured documents.** Call `templates_list` and pick the closest id, then fill it.
   Common ids: `official` (기안문), `enforce` (시행문), `public-notice` (공고문), `press` (보도자료),
   `result-report` (결과 보고서), `report`, `weekly`, `minutes`, `proposal`, `bizplan` (사업계획서),
   `approval` (품의서), `contract`, `nda`, `labor` (표준근로계약서), `employment-cert` (재직증명서),
   `quote` (견적서), `invoice`, `statement` (거래명세서), `budget`, `gantt`, `resume-ko`, `pitch`.
   The list changes — always confirm with `templates_list`.
5. **Hand back a link.** Tool results include an `open_url` (documents open at
   `https://nobami.com/app/?view=drive&doc=<id>`; a template-only `doc_create` returns
   `https://nobami.com/app/?tpl=<templateId>`). Give that link to the user so they can open the file in Nobami.
6. **PDFs are text to you.** `doc_read` on a PDF returns the extracted (editor/OCR) text and metadata, not the
   page images — say so if layout or images matter.
7. **Never invent content the user must stand behind** (amounts, dates, legal clauses, names). Leave a
   clear placeholder such as `[금액]` and point it out.

## Korean document conventions (공문서)

Follow 「행정 효율과 협업 촉진에 관한 규정」 when the user asks for an official document:

- **Structure:** 두문(행정기관명 · 수신 · 경유) → 본문(제목 · 내용 · 붙임) → 결문(발신명의 · 기안자/검토자/결재권자 ·
  시행 번호와 일자 · 접수 · 우편번호와 주소 · 전화/전송 · 전자우편 · 공개 구분).
- **Item symbols, in this order:** `1.` → `가.` → `1)` → `가)` → `(1)` → `(가)` → `①` → `㉮`.
  Indent each level by two spaces (한글 기준 2타). Do not skip levels.
- **Opening line:** reference related documents first, e.g. `1. 관련: 정보보안과-1234(2026. 10. 2.)`.
- **Dates and times:** `2026. 10. 14.` (마침표 뒤 한 칸, 마지막에도 마침표), weekday as `2026. 10. 14.(수)`,
  24-hour time `14:30`.
- **Money:** `금 1,250,000원(금일백이십오만원)`.
- **Ending:** finish the body with `끝.` two spaces after the last sentence; if there is an attachment, end the
  붙임 line with `끝.` instead (`붙임  교육 일정표 1부.  끝.`).
- **Tone:** formal declarative (하십시오체/합니다체), no emoji, no exclamation marks.

For business reports (보고서), use a one-line 요약 at the top, then `□` / `○` / `-` bullets if the user's
organisation uses that style (ask if unsure).

## Formats and export

- Nobami opens and saves **HWP and HWPX** natively. When the user needs a file for 한컴오피스 or a government
  portal, create the document in Nobami and tell them to export it as **HWPX** (File → Download → HWPX); HWPX is
  the format most portals accept today. Use DOCX for Microsoft Word users and PDF for final, read-only copies.
- Spreadsheets: keep formulas (e.g. `=SUM(B2:B10)`) rather than pasting computed values.
- Slides: one idea per slide, 3–5 bullets, speaker notes for detail.

## Privacy

Only read the files the task needs. Do not copy document contents into other services unless the user asks.
Nobami does not use the user's documents to train AI models; every tool call is recorded in the user's audit log.
