builtsimple-research 1.0.0__tar.gz → 1.0.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: builtsimple-research
3
- Version: 1.0.0
3
+ Version: 1.0.1
4
4
  Summary: Unified API for PubMed, ArXiv, and Wikipedia semantic search
5
5
  Project-URL: Homepage, https://built-simple.ai
6
6
  Project-URL: Repository, https://github.com/Built-Simple/python-builtsimple
@@ -2,7 +2,7 @@
2
2
  import httpx
3
3
  from typing import List, Optional, Dict, Any
4
4
 
5
- __version__ = "1.0.0"
5
+ __version__ = "1.0.1"
6
6
 
7
7
  BASE_URLS = {
8
8
  "pubmed": "https://pubmed.built-simple.ai",
@@ -12,9 +12,9 @@ BASE_URLS = {
12
12
 
13
13
  async def search_pubmed(query: str, limit: int = 10) -> List[Dict[str, Any]]:
14
14
  """Search PubMed biomedical literature."""
15
- async with httpx.AsyncClient() as client:
15
+ async with httpx.AsyncClient(timeout=60.0) as client:
16
16
  response = await client.post(
17
- f"{BASE_URLS['pubmed']}/search",
17
+ f"{BASE_URLS['pubmed']}/hybrid-search",
18
18
  json={"query": query, "limit": limit}
19
19
  )
20
20
  data = response.json()
@@ -54,8 +54,9 @@ async def search_all(query: str, limit: int = 10) -> List[Dict[str, Any]]:
54
54
  def search_pubmed_sync(query: str, limit: int = 10) -> List[Dict[str, Any]]:
55
55
  """Synchronous PubMed search."""
56
56
  response = httpx.post(
57
- f"{BASE_URLS['pubmed']}/search",
58
- json={"query": query, "limit": limit}
57
+ f"{BASE_URLS['pubmed']}/hybrid-search",
58
+ json={"query": query, "limit": limit},
59
+ timeout=60.0
59
60
  )
60
61
  return [{"source": "PubMed", **r} for r in response.json().get("results", [])]
61
62
 
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "builtsimple-research"
7
- version = "1.0.0"
7
+ version = "1.0.1"
8
8
  description = "Unified API for PubMed, ArXiv, and Wikipedia semantic search"
9
9
  readme = "README.md"
10
10
  license = "MIT"