Overview
Tool Name
Purpose
The git_action tool provides Git workflows for content your data agents create. It supports file operations, branching, diffs, and history, and can auto-register saved files so they are immediately available to other tools and entities across the platform.Key Features & Functions
File Operations and Diffs
Read and write repository files, generate diffs, and apply unified patches.
Commit and Branch Management
Create branches, switch context, commit changes, and keep work isolated.
History and Status Tracking
Inspect commit history and working tree status to audit changes.
Save and Register Workflow
Use a single call to save a file from disk into Git and auto-register and attach it.
PDF Parsing
Extract text and metadata from PDFs in your repo or by path.
Input Parameters for Each Function
git_action
Parameters
| Name | Definition | Format |
|---|---|---|
| action | Git operation to perform. Supported values: list_files, read_file, write_to_file, save_file, generate_diff, apply_diff, commit, get_history, create_branch, switch_branch, get_branch, get_status, remove_file. | String |
| Action | Required fields |
|---|---|
list_files | path (optional filter) |
read_file | file_path |
write_to_file | file_path, content |
save_file | source_path, target_path (optional), target_filename (optional), auto_register (optional), auto_attach_entity_type (optional when auto_register is true), auto_attach_entity_id (optional when auto_register is true) |
generate_diff | old_content, new_content, context_lines (optional) |
apply_diff | file_path, diff_content |
commit | commit_message |
get_history | file_path (optional), max_count (optional) |
create_branch | branch_name |
switch_branch | branch_name |
get_branch | (no additional fields) |
get_status | (no additional fields) |
remove_file | file_path |
Prefer
action: save_file with auto_register: true to save to Git and automatically register and attach the file in one step.pdf_parser
Parameters
| Name | Definition | Format |
|---|---|---|
| filepath | Path or URL to a PDF for extraction. | String |
Use Cases
- Repository curation
- List and read files to review generated assets before publishing.
- Document updates
- Write content changes to markdown or config files and commit with a clear message.
- One-call save
- Save a local report into the repo and auto-attach it to the current task for review.
- Change review
- Generate a diff, share it for approval, then apply it and commit.
- Release preparation
- Create a feature branch, make changes, and track history for a clean audit trail.
- PDF ingest
- Parse a PDF and store extracted text alongside the original for indexing.
remove_file**and ** apply_diff**can delete or overwrite content. ** Verify targets and keep changes committed to reversible branches.Workflow/How It Works
- Discover
list_filesto scope the repo orget_statusto see pending changes.
- Isolate
create_branchandswitch_branchto work safely on a feature line.
- Edit
write_to_filefor text edits orsave_filefor efficient binary and one-call save and attach.
- Review
generate_diffandget_historyto validate changes before commit.
- Commit
commitwith a descriptive message and confirm viaget_status.
For binary assets,
save_file avoids loading file bytes into chat context and pairs well with auto-registration and attachment.Integration Relevance
- file_manager_tools to register, attach, download, and paginate file content once saved.
- project_manager_tools to align commits and artifacts with tasks and milestones.
- document_index_tools to index committed docs for search and Q&A.
- artifact_manager_tools to reference generated outputs with durable links.
- google_drive_tools when you also need to export or mirror key outputs.
Configuration Details
- Use relative repository paths for
file_pathfields. - Follow branch naming conventions that match your workflow.
- Write clear
commit_messagevalues for traceability. - When
auto_registeris true, provide correctauto_attach_entity_typeandauto_attach_entity_id. - Keep binary files in appropriate directories to avoid repo bloat.
Limitations or Notes
- Repository initialization and permissions are required for all actions.
- Large binaries can slow clone and history operations.
- Concurrent edits can cause merge conflicts that require manual resolution.
- Network connectivity may be required for remotes and external PDF URLs.
- Auto-registration depends on the availability of
file_manager_tools. - PDF parsing quality varies based on document structure.
Output
- File Operations
- Confirmations for create, modify, remove, and the resulting Git status.
- Diff and Apply
- Unified diff output and application results.
- Commit and Branch
- Commit hash, affected files, and branch confirmations.
- History and Status
- Commit lists with timestamps, authors, and messages, plus working tree status.
- PDF Parsing
- Extracted text and metadata ready for indexing or analysis.

