55
66use pyo3:: prelude:: * ;
77
8- use :: vectorless:: client :: { DocumentFormat , IndexContext , IndexMode , IndexOptions , QueryContext } ;
8+ use :: vectorless:: { DocumentFormat , IndexContext , IndexMode , IndexOptions , QueryContext } ;
99
1010use super :: error:: VectorlessError ;
1111
@@ -31,7 +31,6 @@ fn parse_format(format: &str) -> PyResult<DocumentFormat> {
3131/// mode: Indexing mode - "default", "force", or "incremental".
3232/// generate_summaries: Whether to generate summaries. Default: True.
3333/// generate_description: Whether to generate document description. Default: False.
34- /// include_text: Whether to include node text in the tree. Default: True.
3534/// generate_ids: Whether to generate node IDs. Default: True.
3635/// enable_synonym_expansion: Whether to expand keywords with LLM-generated
3736/// synonyms during indexing. Improves recall for differently-worded queries.
@@ -45,12 +44,11 @@ pub struct PyIndexOptions {
4544#[ pymethods]
4645impl PyIndexOptions {
4746 #[ new]
48- #[ pyo3( signature = ( mode="default" , generate_summaries=true , generate_description=false , include_text= true , generate_ids=true , enable_synonym_expansion=false ) ) ]
47+ #[ pyo3( signature = ( mode="default" , generate_summaries=true , generate_description=false , generate_ids=true , enable_synonym_expansion=false ) ) ]
4948 fn new (
5049 mode : & str ,
5150 generate_summaries : bool ,
5251 generate_description : bool ,
53- include_text : bool ,
5452 generate_ids : bool ,
5553 enable_synonym_expansion : bool ,
5654 ) -> PyResult < Self > {
@@ -71,23 +69,21 @@ impl PyIndexOptions {
7169 }
7270 opts. generate_summaries = generate_summaries;
7371 opts. generate_description = generate_description;
74- opts. include_text = include_text;
7572 opts. generate_ids = generate_ids;
7673 opts. enable_synonym_expansion = enable_synonym_expansion;
7774 Ok ( Self { inner : opts } )
7875 }
7976
8077 fn __repr__ ( & self ) -> String {
8178 format ! (
82- "IndexOptions(mode='{}', generate_summaries={}, generate_description={}, include_text={}, generate_ids={}, enable_synonym_expansion={})" ,
79+ "IndexOptions(mode='{}', generate_summaries={}, generate_description={}, generate_ids={}, enable_synonym_expansion={})" ,
8380 match self . inner. mode {
8481 IndexMode :: Default => "default" ,
8582 IndexMode :: Force => "force" ,
8683 IndexMode :: Incremental => "incremental" ,
8784 } ,
8885 self . inner. generate_summaries,
8986 self . inner. generate_description,
90- self . inner. include_text,
9187 self . inner. generate_ids,
9288 self . inner. enable_synonym_expansion,
9389 )
@@ -270,18 +266,6 @@ impl PyQueryContext {
270266 Self { inner : ctx }
271267 }
272268
273- /// Set whether to include the reasoning chain.
274- fn with_include_reasoning ( & self , include : bool ) -> Self {
275- let ctx = self . inner . clone ( ) . with_include_reasoning ( include) ;
276- Self { inner : ctx }
277- }
278-
279- /// Set the maximum tree traversal depth.
280- fn with_depth_limit ( & self , depth : usize ) -> Self {
281- let ctx = self . inner . clone ( ) . with_depth_limit ( depth) ;
282- Self { inner : ctx }
283- }
284-
285269 fn __repr__ ( & self ) -> String {
286270 "QueryContext(...)" . to_string ( )
287271 }
0 commit comments