@@ -103,18 +103,22 @@ search_response: Any = client.search(
103103)
104104assert isinstance (search_response, LinkupSourcedAnswer)
105105print (search_response.model_dump())
106- # Response:
107- # {
108- # answer="The three major events in the life of Abraham Lincoln are: 1. ...",
109- # sources=[
110- # {
111- # "name": "HISTORY",
112- # "url": "https://www.history.com/topics/us-presidents/abraham-lincoln",
113- # "snippet": "Abraham Lincoln - Facts & Summary - HISTORY ..."
114- # },
115- # ...
116- # ]
117- # }
106+ ```
107+
108+ Which prints:
109+
110+ ``` bash
111+ {
112+ answer=" The three major events in the life of Abraham Lincoln are: 1. ..." ,
113+ sources=[
114+ {
115+ " name" : " HISTORY" ,
116+ " url" : " https://www.history.com/topics/us-presidents/abraham-lincoln" ,
117+ " snippet" : " Abraham Lincoln - Facts & Summary - HISTORY ..."
118+ },
119+ ...
120+ ]
121+ }
118122```
119123
120124Check the code or the
@@ -139,11 +143,15 @@ fetch_response: LinkupFetchResponse = client.fetch(
139143 include_raw_html = True ,
140144)
141145print (fetch_response.model_dump())
142- # Response:
143- # {
144- # markdown="Get started for free, no credit card required...",
145- # raw_html="<!DOCTYPE html><html lang=\"en\"><head>...</head><body>...</body></html>"
146- # }
146+ ```
147+
148+ Which prints:
149+
150+ ``` bash
151+ {
152+ markdown=" Get started for free, no credit card required..." ,
153+ raw_html=" <!DOCTYPE html><html lang=\" en\" ><head>...</head><body>...</body></html>"
154+ }
147155```
148156
149157Check the code or the
@@ -175,18 +183,22 @@ async def main() -> None:
175183 print (search_response.model_dump())
176184
177185asyncio.run(main())
178- # Response:
179- # {
180- # answer="The three major events in the life of Abraham Lincoln are: 1. ...",
181- # sources=[
182- # {
183- # "name": "HISTORY",
184- # "url": "https://www.history.com/topics/us-presidents/abraham-lincoln",
185- # "snippet": "Abraham Lincoln - Facts & Summary - HISTORY ..."
186- # },
187- # ...
188- # ]
189- # }
186+ ```
187+
188+ Which prints:
189+
190+ ``` bash
191+ {
192+ answer=" The three major events in the life of Abraham Lincoln are: 1. ..." ,
193+ sources=[
194+ {
195+ " name" : " HISTORY" ,
196+ " url" : " https://www.history.com/topics/us-presidents/abraham-lincoln" ,
197+ " snippet" : " Abraham Lincoln - Facts & Summary - HISTORY ..."
198+ },
199+ ...
200+ ]
201+ }
190202```
191203
192204#### 📚 More Examples
0 commit comments