@@ -302,7 +302,7 @@ var webScreenshot = requestflag.WithInnerFlags(cli.Command{
302302
303303var webSearch = requestflag .WithInnerFlags (cli.Command {
304304 Name : "search" ,
305- Usage : "Search the web and optionally return page content with each result ." ,
305+ Usage : "Search the web and optionally return page content or relevant passages with each\n result ." ,
306306 Suggest : true ,
307307 Flags : []cli.Flag {
308308 & requestflag.Flag [string ]{
@@ -326,6 +326,11 @@ var webSearch = requestflag.WithInnerFlags(cli.Command{
326326 Usage : "Restrict results to content published within this window." ,
327327 BodyPath : "freshness" ,
328328 },
329+ & requestflag.Flag [map [string ]any ]{
330+ Name : "highlights-options" ,
331+ Usage : "Passages from each result page that are relevant to the query. Pages are read with the `markdownOptions` settings." ,
332+ BodyPath : "highlightsOptions" ,
333+ },
329334 & requestflag.Flag [[]string ]{
330335 Name : "include-domain" ,
331336 Usage : `Allowlist — only return results from these domains. Example: ["arxiv.org", "github.com"].` ,
@@ -367,10 +372,22 @@ var webSearch = requestflag.WithInnerFlags(cli.Command{
367372 Action : handleWebSearch ,
368373 HideHelpCommand : true ,
369374}, map [string ][]requestflag.HasOuterFlag {
375+ "highlights-options" : {
376+ & requestflag.InnerFlag [bool ]{
377+ Name : "highlights-options.enabled" ,
378+ Usage : "Return relevant passages for each result. Adds 1 credit per 10 results." ,
379+ InnerField : "enabled" ,
380+ },
381+ & requestflag.InnerFlag [int64 ]{
382+ Name : "highlights-options.max-characters" ,
383+ Usage : "Maximum combined length of passages per result." ,
384+ InnerField : "maxCharacters" ,
385+ },
386+ },
370387 "markdown-options" : {
371388 & requestflag.InnerFlag [bool ]{
372389 Name : "markdown-options.enabled" ,
373- Usage : "Scrape each result to Markdown. Off by default to keep search cheap and fast ." ,
390+ Usage : "Scrape each result to Markdown. Adds 1 credit per 10 results ." ,
374391 InnerField : "enabled" ,
375392 },
376393 & requestflag.InnerFlag [bool ]{
@@ -390,7 +407,7 @@ var webSearch = requestflag.WithInnerFlags(cli.Command{
390407 },
391408 & requestflag.InnerFlag [int64 ]{
392409 Name : "markdown-options.max-age-ms" ,
393- Usage : "Cache TTL in ms for scraped Markdown keyed by URL + options. Default 1 day , max 30 days. Set to 0 to force a fresh scrape." ,
410+ Usage : "Cache TTL in ms for scraped Markdown keyed by URL + options. Default 15 days , max 30 days. Set to 0 to force a fresh scrape." ,
394411 InnerField : "maxAgeMs" ,
395412 },
396413 & requestflag.InnerFlag [map [string ]any ]{
0 commit comments