larksuite / larksuite/cli

Feature: Support inserting LaTeX equation blocks or media at specific document positions

Open
#552 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Go
Stars
17.3k
Forks
1.4k
Avg merge
2d 4h
Merged PRs (30d)
105

Description

Problem

When writing academic documentation with mathematical formulas, users need to insert equation blocks at precise positions in the document (e.g., right after explanatory text). Currently docs +media-insert only appends to the document end.

Current Limitations

  1. docs +media-insert does not support --index parameter for positional insertion
  2. docs +update --mode insert_after works only for text, not media blocks
  3. No API support for native Feishu equation blocks (block_type for LaTeX equations)

Requested Features

  1. Support --index in docs +media-insert to insert at specific positions
  2. Support inserting equation/LaTeX blocks at specific positions
  3. Support insert_after mode with media files

Example Use Case

Writing paper research notes requiring formulas like:

  • Token Merger: h_{v_i} = Linear( Concat( e(s^1), e(s^2), e(s^3) ) )
  • GRPO-SR Loss: L_{GRPO-SR}(θ) = L_{policy} + α · L_{nll}

These need to appear right after explanatory text, not just at document end.

Current Workaround

Users must manually insert formulas via Feishu desktop client, breaking API-first workflow.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the implementations of docs +media-insert and docs +update --mode insert_after, then inspect how document blocks are sent to the Feishu API. Done means positional insertion works with media and LaTeX equation blocks, including --index and insert_after, without requiring the desktop client.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, latex
Domain
api, cli, documentation
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.