langchain-fireworks 0.2.0.dev0__tar.gz → 0.2.0.dev2__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.1
2
2
  Name: langchain-fireworks
3
- Version: 0.2.0.dev0
3
+ Version: 0.2.0.dev2
4
4
  Summary: An integration package connecting Fireworks and LangChain
5
5
  Home-page: https://github.com/langchain-ai/langchain
6
6
  License: MIT
@@ -13,7 +13,7 @@ Classifier: Programming Language :: Python :: 3.11
13
13
  Classifier: Programming Language :: Python :: 3.12
14
14
  Requires-Dist: aiohttp (>=3.9.1,<4.0.0)
15
15
  Requires-Dist: fireworks-ai (>=0.13.0)
16
- Requires-Dist: langchain-core (>=0.3.0.dev1,<0.4.0)
16
+ Requires-Dist: langchain-core (>=0.3.0.dev5,<0.4.0)
17
17
  Requires-Dist: openai (>=1.10.0,<2.0.0)
18
18
  Requires-Dist: requests (>=2,<3)
19
19
  Project-URL: Repository, https://github.com/langchain-ai/langchain
@@ -464,7 +464,7 @@ class ChatFireworks(BaseChatModel):
464
464
  default_chunk_class: Type[BaseMessageChunk] = AIMessageChunk
465
465
  for chunk in self.client.create(messages=message_dicts, **params):
466
466
  if not isinstance(chunk, dict):
467
- chunk = chunk.dict()
467
+ chunk = chunk.model_dump()
468
468
  if len(chunk["choices"]) == 0:
469
469
  continue
470
470
  choice = chunk["choices"][0]
@@ -520,7 +520,7 @@ class ChatFireworks(BaseChatModel):
520
520
  def _create_chat_result(self, response: Union[dict, BaseModel]) -> ChatResult:
521
521
  generations = []
522
522
  if not isinstance(response, dict):
523
- response = response.dict()
523
+ response = response.model_dump()
524
524
  token_usage = response.get("usage", {})
525
525
  for res in response["choices"]:
526
526
  message = _convert_dict_to_message(res["message"])
@@ -558,7 +558,7 @@ class ChatFireworks(BaseChatModel):
558
558
  default_chunk_class: Type[BaseMessageChunk] = AIMessageChunk
559
559
  async for chunk in self.async_client.acreate(messages=message_dicts, **params):
560
560
  if not isinstance(chunk, dict):
561
- chunk = chunk.dict()
561
+ chunk = chunk.model_dump()
562
562
  if len(chunk["choices"]) == 0:
563
563
  continue
564
564
  choice = chunk["choices"][0]
@@ -1,10 +1,10 @@
1
1
  [build-system]
2
- requires = [ "poetry-core>=1.0.0",]
2
+ requires = ["poetry-core>=1.0.0"]
3
3
  build-backend = "poetry.core.masonry.api"
4
4
 
5
5
  [tool.poetry]
6
6
  name = "langchain-fireworks"
7
- version = "0.2.0.dev0"
7
+ version = "0.2.0.dev2"
8
8
  description = "An integration package connecting Fireworks and LangChain"
9
9
  authors = []
10
10
  readme = "README.md"
@@ -20,21 +20,25 @@ disallow_untyped_defs = "True"
20
20
 
21
21
  [tool.poetry.dependencies]
22
22
  python = ">=3.9,<4.0"
23
- langchain-core = { version = "^0.3.0.dev1", allow-prereleases = true }
23
+ langchain-core = { version = "^0.3.0.dev5", allow-prereleases = true }
24
24
  fireworks-ai = ">=0.13.0"
25
25
  openai = "^1.10.0"
26
26
  requests = "^2"
27
27
  aiohttp = "^3.9.1"
28
28
 
29
29
  [tool.ruff.lint]
30
- select = [ "E", "F", "I", "T201",]
30
+ select = ["E", "F", "I", "T201"]
31
31
 
32
32
  [tool.coverage.run]
33
- omit = [ "tests/*",]
33
+ omit = ["tests/*"]
34
34
 
35
35
  [tool.pytest.ini_options]
36
36
  addopts = "--snapshot-warn-unused --strict-markers --strict-config --durations=5"
37
- markers = [ "requires: mark tests as requiring a specific library", "asyncio: mark tests as requiring asyncio", "compile: mark placeholder test used to compile integration tests without running them",]
37
+ markers = [
38
+ "requires: mark tests as requiring a specific library",
39
+ "asyncio: mark tests as requiring asyncio",
40
+ "compile: mark placeholder test used to compile integration tests without running them",
41
+ ]
38
42
  asyncio_mode = "auto"
39
43
 
40
44
  [tool.poetry.group.test]