Skip to content

Conversation

@jqnatividad
Copy link
Collaborator

As the prompt templates span multiple lines which need to be escaped in JSON, making for harder to edit prompts.

With TOML, the linebreaks are visually preserved and far more human-readable.

also updated other indirect dependencies
as TOML is easier to edit, as linebreaks in JSON are escaped, and unescaping them will make the JSON invalid
@jqnatividad jqnatividad requested a review from Copilot September 1, 2025 03:41
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR migrates the describegpt command's prompt file format from JSON to TOML for improved readability and easier editing of multi-line prompt templates.

  • Converts the default prompt file from JSON to TOML format with better visual formatting for multi-line strings
  • Updates the code to parse TOML instead of JSON format
  • Updates documentation and package configuration to reference the new TOML file

Reviewed Changes

Copilot reviewed 5 out of 6 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/cmd/describegpt.rs Updates parser from JSON to TOML, adds toml dependency import, and updates documentation strings
resources/describegpt_defaults.toml New TOML format prompt file with improved multi-line string formatting
resources/describegpt_defaults.json Removes the old JSON format prompt file
docs/Describegpt.md Updates documentation to reference the new TOML file
Cargo.toml Adds toml dependency and updates package includes

@jqnatividad jqnatividad merged commit fc32fb3 into master Sep 1, 2025
12 of 13 checks passed
@jqnatividad jqnatividad deleted the describegpt-prompt-file-migrate-to-toml branch September 1, 2025 03:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants