Skip to content

Conversation

@Khurdhula-Harshavardhan
Copy link
Collaborator

This pull request introduces several enhancements and improvements to the API parameter handling across multiple modules. The main changes include expanding the use of NotRequired for optional parameters, adding new fields for greater flexibility, and improving documentation for several TypedDicts. These updates make the API more robust and easier to use, allowing for more granular control and clearer parameter expectations.

API Parameter Enhancements

  • Added new optional fields (dimensions, instruction, query) to EmbeddingV2Params in jigsawstack/embedding_v2.py to support advanced embedding configurations.
  • Updated PredictionParams in jigsawstack/prediction.py so that steps is now optional, with improved documentation for valid ranges and defaults.
  • Added name as an optional field to PromptEngineCreateParams in jigsawstack/prompt_engine.py for better prompt identification.
  • Added max_results as an optional parameter to SearchParams in jigsawstack/search.py, along with logic to include it in search requests. [1] [2] [3]
  • Added fine_grained as an optional parameter to VOCRParams in jigsawstack/vision.py to enable high-fidelity word-level bounding boxes.

Type and Documentation Improvements

  • Expanded element_prompts in AIScrapeParams (jigsawstack/web.py) to accept either a list or a dictionary, with detailed documentation on limits and usage.
  • Updated imports to use NotRequired from typing_extensions in relevant files for consistency.

Minor Refactoring

  • Improved method signatures for better readability and consistency in embedding_v2.py and prompt_engine.py. [1] [2] [3] [4]

Copy link
Collaborator

@VineeTagarwaL-code VineeTagarwaL-code left a comment

Choose a reason for hiding this comment

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

Looks good!

@Khurdhula-Harshavardhan Khurdhula-Harshavardhan merged commit 92f18f1 into main Dec 1, 2025
32 of 34 checks passed
@Khurdhula-Harshavardhan Khurdhula-Harshavardhan deleted the fix/types branch December 1, 2025 18:45
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.

3 participants