Skip to content

feat: add API integration for external proofreading service#28

Open
nathanredblur wants to merge 4 commits intoonderceylan:mainfrom
nathanredblur:feat-support-api
Open

feat: add API integration for external proofreading service#28
nathanredblur wants to merge 4 commits intoonderceylan:mainfrom
nathanredblur:feat-support-api

Conversation

@nathanredblur
Copy link

  • Introduced API configuration options in the settings, allowing users to connect to a model running in a service using API
  • Implemented functionality to test API connection and fetch available models.
  • Updated storage management to handle API configuration and model source selection.
  • Enhanced the background service to support API-based proofreading requests.
  • Added UI elements for API configuration in the options page.

(just claudeAPI protocol compatible for now)
Inspired on how Grammit extension works.

* Introduced API configuration options in the settings, allowing users to connect to an external AI proofreading service.
* Implemented functionality to test API connection and fetch available models.
* Updated storage management to handle API configuration and model source selection.
* Enhanced the background service to support API-based proofreading requests.
* Added UI elements for API configuration in the options page.
* Added support for Gemini and OpenAI-compatible APIs in the configuration options.
* Enhanced the API configuration UI to include new options for selecting API types.
* Implemented functionality to handle API-specific connection testing and model fetching.
* Updated the proofreading logic to accommodate different API response formats and correction handling.
* Refactored utility functions for improved code organization and reusability.
* Updated model readiness logic to check the model source before ensuring the proofreader model is ready.
* Refactored the isModelReady function to include model source in its checks.
* Improved consistency in handling model readiness across different modules (main, options, sidepanel).
* Added retrieval of model source from storage to update the model source cache during badge listener registration.
* Modified the API request structure to include the system prompt in the user message for improved context during proofreading.
@nathanredblur nathanredblur mentioned this pull request Mar 2, 2026
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.

1 participant