Class: OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore
- Defined in:
- lib/openai/models/beta/thread_create_and_run_params.rb
Defined Under Namespace
Modules: ChunkingStrategy
Instance Attribute Summary collapse
-
#chunking_strategy ⇒ OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Auto, ...
The chunking strategy used to chunk the file(s).
-
#file_ids ⇒ Array<String>?
A list of [file](platform.openai.com/docs/api-reference/files) IDs to add to the vector store.
-
#metadata ⇒ Hash{Symbol=>String}?
Set of 16 key-value pairs that can be attached to an object.
Instance Method Summary collapse
-
#initialize(chunking_strategy: nil, file_ids: nil, metadata: nil) ⇒ Object
constructor
Some parameter documentations has been truncated, see VectorStore for more details.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, #inspect, inspect, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(chunking_strategy: nil, file_ids: nil, metadata: nil) ⇒ Object
Some parameter documentations has been truncated, see OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore for more details.
482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 |
# File 'lib/openai/models/beta/thread_create_and_run_params.rb', line 482 class VectorStore < OpenAI::Internal::Type::BaseModel # @!attribute chunking_strategy # The chunking strategy used to chunk the file(s). If not set, will use the `auto` # strategy. # # @return [OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Auto, OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static, nil] optional :chunking_strategy, union: -> { OpenAI::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy } # @!attribute file_ids # A list of [file](https://platform.openai.com/docs/api-reference/files) IDs to # add to the vector store. There can be a maximum of 10000 files in a vector # store. # # @return [Array<String>, nil] optional :file_ids, OpenAI::Internal::Type::ArrayOf[String] # @!attribute metadata # Set of 16 key-value pairs that can be attached to an object. This can be useful # for storing additional information about the object in a structured format, and # querying for objects via API or the dashboard. # # Keys are strings with a maximum length of 64 characters. Values are strings with # a maximum length of 512 characters. # # @return [Hash{Symbol=>String}, nil] optional :metadata, OpenAI::Internal::Type::HashOf[String], nil?: true # @!method initialize(chunking_strategy: nil, file_ids: nil, metadata: nil) # Some parameter documentations has been truncated, see # {OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore} # for more details. # # @param chunking_strategy [OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Auto, OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static] The chunking strategy used to chunk the file(s). If not set, will use the `auto` # # @param file_ids [Array<String>] A list of [file](https://platform.openai.com/docs/api-reference/files) IDs to ad # # @param metadata [Hash{Symbol=>String}, nil] Set of 16 key-value pairs that can be attached to an object. This can be # The chunking strategy used to chunk the file(s). If not set, will use the `auto` # strategy. # # @see OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore#chunking_strategy module ChunkingStrategy extend OpenAI::Internal::Type::Union discriminator :type # The default strategy. This strategy currently uses a `max_chunk_size_tokens` of `800` and `chunk_overlap_tokens` of `400`. variant :auto, -> { OpenAI::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Auto } variant :static, -> { OpenAI::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static } class Auto < OpenAI::Internal::Type::BaseModel # @!attribute type # Always `auto`. # # @return [Symbol, :auto] required :type, const: :auto # @!method initialize(type: :auto) # The default strategy. This strategy currently uses a `max_chunk_size_tokens` of # `800` and `chunk_overlap_tokens` of `400`. # # @param type [Symbol, :auto] Always `auto`. end class Static < OpenAI::Internal::Type::BaseModel # @!attribute static # # @return [OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static::Static] required :static, -> { OpenAI::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static::Static } # @!attribute type # Always `static`. # # @return [Symbol, :static] required :type, const: :static # @!method initialize(static:, type: :static) # @param static [OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static::Static] # # @param type [Symbol, :static] Always `static`. # @see OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static#static class Static < OpenAI::Internal::Type::BaseModel # @!attribute chunk_overlap_tokens # The number of tokens that overlap between chunks. The default value is `400`. # # Note that the overlap must not exceed half of `max_chunk_size_tokens`. # # @return [Integer] required :chunk_overlap_tokens, Integer # @!attribute max_chunk_size_tokens # The maximum number of tokens in each chunk. The default value is `800`. The # minimum value is `100` and the maximum value is `4096`. # # @return [Integer] required :max_chunk_size_tokens, Integer # @!method initialize(chunk_overlap_tokens:, max_chunk_size_tokens:) # Some parameter documentations has been truncated, see # {OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static::Static} # for more details. # # @param chunk_overlap_tokens [Integer] The number of tokens that overlap between chunks. The default value is `400`. # # @param max_chunk_size_tokens [Integer] The maximum number of tokens in each chunk. The default value is `800`. The mini end end # @!method self.variants # @return [Array(OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Auto, OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Static)] end end |
Instance Attribute Details
#chunking_strategy ⇒ OpenAI::Models::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy::Auto, ...
The chunking strategy used to chunk the file(s). If not set, will use the ‘auto` strategy.
488 489 490 491 |
# File 'lib/openai/models/beta/thread_create_and_run_params.rb', line 488 optional :chunking_strategy, union: -> { OpenAI::Beta::ThreadCreateAndRunParams::Thread::ToolResources::FileSearch::VectorStore::ChunkingStrategy } |
#file_ids ⇒ Array<String>?
A list of [file](platform.openai.com/docs/api-reference/files) IDs to add to the vector store. There can be a maximum of 10000 files in a vector store.
499 |
# File 'lib/openai/models/beta/thread_create_and_run_params.rb', line 499 optional :file_ids, OpenAI::Internal::Type::ArrayOf[String] |
#metadata ⇒ Hash{Symbol=>String}?
Set of 16 key-value pairs that can be attached to an object. This can be useful for storing additional information about the object in a structured format, and querying for objects via API or the dashboard.
Keys are strings with a maximum length of 64 characters. Values are strings with a maximum length of 512 characters.
510 |
# File 'lib/openai/models/beta/thread_create_and_run_params.rb', line 510 optional :metadata, OpenAI::Internal::Type::HashOf[String], nil?: true |