Local docs for the daily pathTài liệu local cho công việc hằng ngày

Start small. Know exactly what happens.Bắt đầu gọn. Biết chính xác điều gì xảy ra.

Install Papaya, connect the model you already use, trust one project deliberately, and keep exact help available inside the build.Cài Papaya, kết nối model bạn đang dùng, trust từng dự án có chủ đích, và giữ hướng dẫn chính xác ngay bên trong bản cài.

npm install -g papaya-code

Installation

Papaya ships as one npm-global command. You need Node.js 22.13+. Check first; install only when the command is absent or too old.

node --version
npm install -g papaya-code
papaya --version

First run

Start in the project you want Papaya to understand. Configure a provider, inspect project-controlled sources, then trust the exact canonical root.

cd path/to/your-project
papaya auth key openrouter
papaya trust status
papaya trust add
papaya

Update or remove

papaya update --check compares an npm-global installation with the registry. papaya uninstall removes the package but leaves sessions and settings. Use papaya uninstall --purge only when you also want to review and remove Papaya data.

Cài đặt

Papaya được phát hành dưới dạng một lệnh npm global. Bạn cần Node.js 22.13+. Hãy kiểm tra trước; chỉ cài khi lệnh chưa có hoặc phiên bản quá cũ.

node --version
npm install -g papaya-code
papaya --version

Lần chạy đầu tiên

Khởi động ngay trong dự án bạn muốn Papaya hiểu. Cấu hình provider, kiểm tra các nguồn do dự án kiểm soát, rồi trust đúng canonical root.

cd duong-dan/toi/du-an
papaya auth key openrouter
papaya trust status
papaya trust add
papaya

Cập nhật hoặc gỡ cài đặt

papaya update --check so sánh bản npm global với registry. papaya uninstall gỡ package nhưng giữ session và settings. Chỉ dùng papaya uninstall --purge khi bạn cũng muốn xem và xoá dữ liệu Papaya.

Connect a provider

Use the provider you already have. Local Ollama needs no key; OpenRouter, OpenAI, and Anthropic can read environment variables or a key stored by Papaya. A ChatGPT plan uses the sign-in flow.

papaya auth status
papaya auth key openrouter
papaya auth login chatgpt

Secrets do not belong in project config. Papaya removes supported provider keys and its daemon token from child-process environments.

Kết nối provider

Dùng provider bạn đang có. Ollama local không cần key; OpenRouter, OpenAI và Anthropic có thể đọc biến môi trường hoặc key do Papaya lưu. Gói ChatGPT dùng luồng đăng nhập.

papaya auth status
papaya auth key openrouter
papaya auth login chatgpt

Không để secret trong project config. Papaya loại key của các provider được hỗ trợ và daemon token khỏi environment của child process.

Choose a model

/model changes the session you are in. Press Tab in the picker to also make that choice the default, or write the default explicitly with /config set.

papaya config
# inside the interface
/model
/config set provider openrouter
/config set model deepseek/deepseek-v4-flash-0731

Use a fallback ladder when you want work to continue after a provider or model is unavailable; Papaya drops an unresolvable rung visibly instead of silently changing the request.

Chọn model

/model đổi model cho session hiện tại. Nhấn Tab trong picker để đồng thời đặt lựa chọn đó làm mặc định, hoặc ghi default rõ ràng bằng /config set.

papaya config
# trong giao diện
/model
/config set provider openrouter
/config set model deepseek/deepseek-v4-flash-0731

Dùng fallback ladder khi muốn công việc tiếp tục nếu provider hoặc model không khả dụng; Papaya hiển thị rung không resolve được thay vì âm thầm đổi request.

Project trust

Project trust decides whether a repository may contribute hooks, MCP servers, skills, agents, and instruction files. The decision is tied to the canonical root, not the spelling of the path you used to enter it.

papaya trust status
papaya trust add
papaya trust revoke

Inspect the source list before trusting. Adding trust later does not silently rebuild an already-open untrusted session.

Project trust

Project trust quyết định repository có được đóng góp hook, MCP server, skill, agent và instruction file hay không. Quyết định gắn với canonical root, không gắn với cách viết đường dẫn bạn dùng để đi vào đó.

papaya trust status
papaya trust add
papaya trust revoke

Hãy xem danh sách source trước khi trust. Thêm trust sau đó không âm thầm rebuild một session untrusted đang mở.

Permissions

The permission gate sees tool calls before they run. Plan mode allows observation and refuses changes. Ask mode applies visible allow/deny rules and asks a connected person when a decision remains.

  • Execution authority is one-shot.
  • bypass, allow rules, and allow_always cannot grant outbound network or writes outside the project.
  • An unattended session fails closed when approval is required.
papaya config
# inside the interface
/mode
/config

Permission

Permission gate nhìn thấy tool call trước khi chạy. Plan mode cho phép quan sát và từ chối thay đổi. Ask mode áp dụng rule allow/deny rõ ràng và hỏi người đang kết nối khi chưa có quyết định.

  • Execution authority chỉ dùng một lần.
  • bypass, allow rule và allow_always không thể cấp outbound network hoặc ghi ngoài dự án.
  • Session unattended fail closed khi cần approval.
papaya config
# trong giao diện
/mode
/config

Daemon and web

The localhost daemon owns sessions that should survive one terminal. Attach from another terminal or open the same durable sessions in the browser.

papaya daemon start
papaya daemon status
papaya attach
papaya web
papaya daemon stop

Jobs and schedules live with the daemon. A verified stop distinguishes “termination requested” from cleanup that is actually complete.

Daemon và web

Daemon localhost giữ những session cần sống lâu hơn một terminal. Attach từ terminal khác hoặc mở cùng session bền vững đó trong trình duyệt.

papaya daemon start
papaya daemon status
papaya attach
papaya web
papaya daemon stop

Job và schedule sống cùng daemon. Verified stop phân biệt “đã yêu cầu dừng” với cleanup đã thực sự hoàn tất.

Plugins and hooks

A local plugin is a copied, revalidated bundle of skills, agents, hooks, and stdio MCP declarations. It cannot carry permission rules or declare a remote MCP server.

papaya plugin install ./my-plugin
papaya plugin list
papaya plugin disable my-plugin
papaya plugin remove my-plugin

Permission hooks observe decisions; they cannot decide for the person. Project hooks remain behind project trust.

Plugin và hook

Plugin local là bundle được copy và revalidate, gồm skill, agent, hook và khai báo MCP stdio. Nó không được mang permission rule hoặc khai báo MCP server remote.

papaya plugin install ./my-plugin
papaya plugin list
papaya plugin disable my-plugin
papaya plugin remove my-plugin

Permission hook chỉ quan sát quyết định; nó không thể quyết định thay con người. Project hook vẫn nằm sau project trust.

Worktrees

Subagents can work in temporary Git worktrees without moving the parent process. Papaya journals what it created so cleanup can distinguish its own directories from yours.

papaya worktree list
papaya worktree prune

Exit and prune refuse a dirty checkout and refuse any directory missing from Papaya's journal.

Worktree

Subagent có thể làm việc trong Git worktree tạm mà không đổi process cha. Papaya ghi journal cho những thứ nó tạo để cleanup phân biệt thư mục của nó với của bạn.

papaya worktree list
papaya worktree prune

Exit và prune từ chối checkout dirty, đồng thời từ chối mọi thư mục không nằm trong journal của Papaya.

Ask Papaya about Papaya

Exact user documentation ships inside the installed build. The terminal, interface, and model all read the same version-matched files locally and offline.

papaya help
papaya help jobs
papaya help --search "checkpoint"
# inside the interface
/help permissions

The model uses the read-only ProductHelp tool instead of guessing. Large topics return a section map so one question does not spend the context window on unrelated promises.

Hỏi Papaya về chính Papaya

Tài liệu người dùng chính xác nằm ngay trong bản cài. Terminal, giao diện và model cùng đọc các file đúng phiên bản, local và offline.

papaya help
papaya help jobs
papaya help --search "checkpoint"
# trong giao diện
/help permissions

Model dùng tool read-only ProductHelp thay vì đoán. Chủ đề lớn trả về bản đồ section để một câu hỏi không tiêu tốn context window cho những lời hứa không liên quan.

Troubleshooting

Start with observable state. These commands say which binary is running, what configuration won, whether this project is trusted, and whether an installation journal or old daemon needs attention.

papaya --version
papaya config
papaya trust status
papaya auth status
papaya doctor --installation
papaya daemon status

If a command reaches the wrong model, inspect papaya config rather than inferring active state from a saved preset.

Xử lý sự cố

Bắt đầu từ trạng thái quan sát được. Các lệnh sau cho biết binary nào đang chạy, cấu hình nào thắng, dự án đã trust chưa, và update journal hay daemon cũ có cần xử lý không.

papaya --version
papaya config
papaya trust status
papaya auth status
papaya doctor --installation
papaya daemon status

Nếu lệnh đi tới sai model, hãy xem papaya config thay vì suy ra trạng thái đang chạy từ preset đã lưu.

Security boundary

There is no OS sandbox. Processes Papaya starts run as your operating-system account, with your reach.

The harness still enforces useful boundaries: explicit project trust, per-execution authority, child-environment secret redaction, and process-tree ownership with verified cleanup. These stop mistakes and make consequences visible. They do not contain hostile code.

papaya sandbox status
papaya sandbox doctor

The status command exits non-zero so automation cannot misread “no backend” as successful confinement. Do not point Papaya at a repository you would not run locally.

Ranh giới bảo mật

Không có OS sandbox. Process do Papaya khởi chạy dùng tài khoản hệ điều hành của bạn, với đúng phạm vi quyền của bạn.

Harness vẫn thực thi các ranh giới hữu ích: project trust rõ ràng, authority theo từng execution, lọc secret khỏi child environment và sở hữu process tree với cleanup được xác minh. Chúng ngăn nhầm lẫn và làm hậu quả dễ thấy; chúng không cô lập mã độc.

papaya sandbox status
papaya sandbox doctor

Lệnh status trả exit code khác 0 để automation không thể hiểu nhầm “không có backend” thành confinement thành công. Đừng trỏ Papaya vào repository mà bạn sẽ không tự chạy local.