explaingit

tejass1233/opencode-parser

12TypeScriptAudience · developerComplexity · 2/5LicenseSetup · easy

TLDR

A plugin for the opencode AI coding assistant that converts PDFs, Word docs, spreadsheets, presentations, Jupyter notebooks, and many other file formats into readable text the AI can process.

Mindmap

mindmap
  root((opencode parser))
    What it does
      File format conversion
      Consistent text output
      OCR for images
    Supported formats
      PDF DOCX XLSX PPTX
      EPUB HTML Markdown
      Jupyter notebooks
      ZIP CSV JSON YAML
    Options
      Character limit
      Page and sheet limits
      Save as Markdown
    Installation
      Plugin command
      JSON config entry
      Local source files
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Hand a PDF or Word document to the opencode AI assistant and ask it questions about the content.

USE CASE 2

Parse a multi-sheet Excel file in opencode and ask the AI to summarize each sheet's data.

USE CASE 3

Feed a Jupyter notebook into opencode and ask the AI to explain what the code cells produce.

Tech stack

TypeScript

Getting it running

Difficulty · easy Time to first run · 5min

Install via the opencode plugin command or a one-line JSON config entry.

MIT license. Use, copy, modify, and distribute freely for any purpose, including commercial use, as long as the copyright notice is kept.

In plain English

opencode-parser is a plugin for the opencode AI coding assistant that lets the AI read and work with files in formats it would not otherwise understand. Without a plugin like this, an AI assistant can only see plain text files directly. With opencode-parser installed, you can hand it a PDF, a Word document, a spreadsheet, a PowerPoint file, or many other formats, and the plugin converts the content into structured text the AI can process. The supported formats include PDF, DOCX, XLSX, XLS, CSV, TSV, PPTX, PPT, EPUB, HTML, XML, Markdown, Jupyter notebooks, ZIP files, and plain text formats like JSON, YAML, and TOML. Image files (PNG, JPG, WEBP, and others) can also be processed using OCR text extraction, though that option is off by default and requires enabling it. For spreadsheets, it extracts tables and sheet names. For presentations, it pulls slide text and speaker notes. For Jupyter notebooks, it pulls code cells, markdown cells, and outputs. The plugin verifies file type using the actual binary content of the file rather than just trusting the file extension. All supported formats return results in the same structure, so the AI gets consistent output regardless of what kind of file you pass in. Large files are truncated with a note, or you can set the character limit to unlimited if you need the full content. Options include controlling the maximum number of characters returned, limiting which pages or sheets are processed, enabling OCR for images, and saving the parsed result as a Markdown file alongside the original. Installation is either through the opencode plugin command, a one-line JSON config entry, or by copying the source files into a local tools folder. The project is MIT licensed.

Copy-paste prompts

Prompt 1
Using opencode-parser, load this PDF contract into opencode and summarize the key obligations for each party in plain English.
Prompt 2
Install opencode-parser and use it to read a multi-tab Excel spreadsheet, then ask opencode to identify the top 5 rows by revenue across all sheets.
Prompt 3
Use opencode-parser to parse a Jupyter notebook and ask opencode to convert the analysis into a standalone Python script with comments.
Open on GitHub → Explain another repo

← tejass1233 on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.