langfun 0.1.2.dev202412080804__py3-none-any.whl → 0.1.2.dev202412100804__py3-none-any.whl
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.
- langfun/core/agentic/action.py +719 -133
- langfun/core/agentic/action_test.py +78 -44
- langfun/core/llms/__init__.py +1 -0
- langfun/core/llms/anthropic.py +1 -1
- langfun/core/llms/google_genai.py +31 -41
- langfun/core/llms/vertexai.py +10 -9
- langfun/core/message.py +1 -1
- langfun/core/message_test.py +1 -1
- langfun/core/structured/prompting.py +105 -5
- langfun/core/structured/prompting_test.py +12 -0
- {langfun-0.1.2.dev202412080804.dist-info → langfun-0.1.2.dev202412100804.dist-info}/METADATA +1 -1
- {langfun-0.1.2.dev202412080804.dist-info → langfun-0.1.2.dev202412100804.dist-info}/RECORD +15 -15
- {langfun-0.1.2.dev202412080804.dist-info → langfun-0.1.2.dev202412100804.dist-info}/LICENSE +0 -0
- {langfun-0.1.2.dev202412080804.dist-info → langfun-0.1.2.dev202412100804.dist-info}/WHEEL +0 -0
- {langfun-0.1.2.dev202412080804.dist-info → langfun-0.1.2.dev202412100804.dist-info}/top_level.txt +0 -0
@@ -18,6 +18,8 @@ import unittest
|
|
18
18
|
import langfun.core as lf
|
19
19
|
from langfun.core.agentic import action as action_lib
|
20
20
|
from langfun.core.llms import fake
|
21
|
+
import langfun.core.structured as lf_structured
|
22
|
+
import pyglove as pg
|
21
23
|
|
22
24
|
|
23
25
|
class SessionTest(unittest.TestCase):
|
@@ -28,60 +30,92 @@ class SessionTest(unittest.TestCase):
|
|
28
30
|
class Bar(action_lib.Action):
|
29
31
|
|
30
32
|
def call(self, session, *, lm, **kwargs):
|
31
|
-
test.assertIs(session.
|
33
|
+
test.assertIs(session.current_action.action, self)
|
32
34
|
session.info('Begin Bar')
|
33
35
|
session.query('bar', lm=lm)
|
34
|
-
return 2
|
36
|
+
return 2, dict(note='bar')
|
35
37
|
|
36
38
|
class Foo(action_lib.Action):
|
37
39
|
x: int
|
38
40
|
|
39
41
|
def call(self, session, *, lm, **kwargs):
|
40
|
-
test.assertIs(session.
|
41
|
-
session.
|
42
|
-
|
43
|
-
|
42
|
+
test.assertIs(session.current_action.action, self)
|
43
|
+
with session.phase('prepare'):
|
44
|
+
session.info('Begin Foo', x=1)
|
45
|
+
session.query('foo', lm=lm)
|
46
|
+
with session.track_queries():
|
47
|
+
self.make_additional_query(lm)
|
48
|
+
return self.x + Bar()(session, lm=lm), dict(note='foo')
|
49
|
+
|
50
|
+
def make_additional_query(self, lm):
|
51
|
+
lf_structured.query('additional query', lm=lm)
|
44
52
|
|
45
53
|
lm = fake.StaticResponse('lm response')
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
self.
|
51
|
-
self.
|
52
|
-
self.
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
self.assertEqual(len(
|
60
|
-
self.
|
61
|
-
|
62
|
-
|
63
|
-
)
|
64
|
-
self.
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
)
|
69
|
-
self.assertEqual(
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
)
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
78
|
-
)
|
79
|
-
|
80
|
-
self.
|
81
|
-
|
82
|
-
|
83
|
-
|
54
|
+
foo = Foo(1)
|
55
|
+
self.assertEqual(foo(lm=lm), 3)
|
56
|
+
|
57
|
+
session = foo.session
|
58
|
+
self.assertIsNotNone(session)
|
59
|
+
self.assertIsInstance(session.root.action, action_lib.RootAction)
|
60
|
+
self.assertIs(session.current_action, session.root)
|
61
|
+
|
62
|
+
#
|
63
|
+
# Inspecting the root invocation.
|
64
|
+
#
|
65
|
+
|
66
|
+
root = session.root
|
67
|
+
self.assertEqual(len(root.execution.items), 1)
|
68
|
+
self.assertIs(root.execution.items[0].action, foo)
|
69
|
+
|
70
|
+
self.assertTrue(root.execution.has_started)
|
71
|
+
self.assertTrue(root.execution.has_stopped)
|
72
|
+
self.assertGreater(root.execution.elapse, 0)
|
73
|
+
self.assertEqual(root.result, 3)
|
74
|
+
self.assertEqual(root.result_metadata, dict(note='foo'))
|
75
|
+
|
76
|
+
# The root space should have one action (foo), no queries, and no logs.
|
77
|
+
self.assertEqual(len(list(root.actions)), 1)
|
78
|
+
self.assertEqual(len(list(root.queries)), 0)
|
79
|
+
self.assertEqual(len(list(root.logs)), 0)
|
80
|
+
# 1 query from Bar and 2 from Foo.
|
81
|
+
self.assertEqual(len(list(root.all_queries)), 3)
|
82
|
+
# 1 log from Bar and 1 from Foo.
|
83
|
+
self.assertEqual(len(list(root.all_logs)), 2)
|
84
|
+
self.assertEqual(root.usage_summary.total.num_requests, 3)
|
85
|
+
|
86
|
+
# Inspecting the top-level action (Foo)
|
87
|
+
foo_invocation = root.execution.items[0]
|
88
|
+
self.assertEqual(len(foo_invocation.execution.items), 3)
|
89
|
+
|
90
|
+
# Prepare phase.
|
91
|
+
prepare_phase = foo_invocation.execution.items[0]
|
92
|
+
self.assertIsInstance(
|
93
|
+
prepare_phase, action_lib.ExecutionTrace
|
84
94
|
)
|
95
|
+
self.assertEqual(len(prepare_phase.items), 2)
|
96
|
+
self.assertTrue(prepare_phase.has_started)
|
97
|
+
self.assertTrue(prepare_phase.has_stopped)
|
98
|
+
self.assertEqual(prepare_phase.usage_summary.total.num_requests, 1)
|
99
|
+
|
100
|
+
# Tracked queries.
|
101
|
+
query_invocation = foo_invocation.execution.items[1]
|
102
|
+
self.assertIsInstance(query_invocation, lf_structured.QueryInvocation)
|
103
|
+
self.assertIs(query_invocation.lm, lm)
|
104
|
+
|
105
|
+
# Invocation to Bar.
|
106
|
+
bar_invocation = foo_invocation.execution.items[2]
|
107
|
+
self.assertIsInstance(bar_invocation, action_lib.ActionInvocation)
|
108
|
+
self.assertIsInstance(bar_invocation.action, Bar)
|
109
|
+
self.assertEqual(bar_invocation.result, 2)
|
110
|
+
self.assertEqual(bar_invocation.result_metadata, dict(note='bar'))
|
111
|
+
self.assertEqual(len(bar_invocation.execution.items), 2)
|
112
|
+
|
113
|
+
# Save to HTML
|
114
|
+
self.assertIn('invocation-result', session.to_html().content)
|
115
|
+
|
116
|
+
# Save session to JSON
|
117
|
+
json_str = session.to_json_str(save_ref_value=True)
|
118
|
+
self.assertIsInstance(pg.from_json_str(json_str), action_lib.Session)
|
85
119
|
|
86
120
|
def test_log(self):
|
87
121
|
session = action_lib.Session()
|
langfun/core/llms/__init__.py
CHANGED
@@ -33,6 +33,7 @@ from langfun.core.llms.rest import REST
|
|
33
33
|
# Gemini models.
|
34
34
|
from langfun.core.llms.google_genai import GenAI
|
35
35
|
from langfun.core.llms.google_genai import GeminiExp_20241114
|
36
|
+
from langfun.core.llms.google_genai import GeminiExp_20241206
|
36
37
|
from langfun.core.llms.google_genai import GeminiFlash1_5
|
37
38
|
from langfun.core.llms.google_genai import GeminiPro
|
38
39
|
from langfun.core.llms.google_genai import GeminiPro1_5
|
langfun/core/llms/anthropic.py
CHANGED
@@ -20,6 +20,7 @@ from typing import Annotated, Any, Literal
|
|
20
20
|
|
21
21
|
import langfun.core as lf
|
22
22
|
from langfun.core import modalities as lf_modalities
|
23
|
+
from langfun.core.llms import vertexai
|
23
24
|
import pyglove as pg
|
24
25
|
|
25
26
|
|
@@ -54,6 +55,7 @@ class GenAI(lf.LanguageModel):
|
|
54
55
|
'gemini-1.5-pro-latest',
|
55
56
|
'gemini-1.5-flash-latest',
|
56
57
|
'gemini-exp-1114',
|
58
|
+
'gemini-exp-1206',
|
57
59
|
],
|
58
60
|
'Model name.',
|
59
61
|
]
|
@@ -306,64 +308,52 @@ _GOOGLE_GENAI_MODEL_HUB = _ModelHub()
|
|
306
308
|
#
|
307
309
|
|
308
310
|
|
309
|
-
|
310
|
-
|
311
|
-
|
312
|
-
|
313
|
-
|
314
|
-
|
315
|
-
|
316
|
-
|
317
|
-
|
318
|
-
|
319
|
-
'audio/flac',
|
320
|
-
'audio/mp3',
|
321
|
-
'audio/m4a',
|
322
|
-
'audio/mpeg',
|
323
|
-
'audio/mpga',
|
324
|
-
'audio/mp4',
|
325
|
-
'audio/opus',
|
326
|
-
'audio/pcm',
|
327
|
-
'audio/wav',
|
328
|
-
'audio/webm'
|
329
|
-
]
|
330
|
-
|
331
|
-
_VIDEO_TYPES = [
|
332
|
-
'video/mov',
|
333
|
-
'video/mpeg',
|
334
|
-
'video/mpegps',
|
335
|
-
'video/mpg',
|
336
|
-
'video/mp4',
|
337
|
-
'video/webm',
|
338
|
-
'video/wmv',
|
339
|
-
'video/x-flv',
|
340
|
-
'video/3gpp',
|
341
|
-
]
|
342
|
-
|
343
|
-
_PDF = [
|
344
|
-
'application/pdf',
|
345
|
-
]
|
311
|
+
class GeminiExp_20241206(GenAI): # pylint: disable=invalid-name
|
312
|
+
"""Gemini Experimental model launched on 12/06/2024."""
|
313
|
+
|
314
|
+
model = 'gemini-exp-1206'
|
315
|
+
supported_modalities = (
|
316
|
+
vertexai.DOCUMENT_TYPES
|
317
|
+
+ vertexai.IMAGE_TYPES
|
318
|
+
+ vertexai.AUDIO_TYPES
|
319
|
+
+ vertexai.VIDEO_TYPES
|
320
|
+
)
|
346
321
|
|
347
322
|
|
348
323
|
class GeminiExp_20241114(GenAI): # pylint: disable=invalid-name
|
349
324
|
"""Gemini Experimental model launched on 11/14/2024."""
|
350
325
|
|
351
326
|
model = 'gemini-exp-1114'
|
352
|
-
supported_modalities =
|
327
|
+
supported_modalities = (
|
328
|
+
vertexai.DOCUMENT_TYPES
|
329
|
+
+ vertexai.IMAGE_TYPES
|
330
|
+
+ vertexai.AUDIO_TYPES
|
331
|
+
+ vertexai.VIDEO_TYPES
|
332
|
+
)
|
353
333
|
|
354
334
|
|
355
335
|
class GeminiPro1_5(GenAI): # pylint: disable=invalid-name
|
356
336
|
"""Gemini Pro latest model."""
|
357
337
|
|
358
338
|
model = 'gemini-1.5-pro-latest'
|
359
|
-
supported_modalities =
|
339
|
+
supported_modalities = (
|
340
|
+
vertexai.DOCUMENT_TYPES
|
341
|
+
+ vertexai.IMAGE_TYPES
|
342
|
+
+ vertexai.AUDIO_TYPES
|
343
|
+
+ vertexai.VIDEO_TYPES
|
344
|
+
)
|
360
345
|
|
361
346
|
|
362
347
|
class GeminiFlash1_5(GenAI): # pylint: disable=invalid-name
|
363
348
|
"""Gemini Flash latest model."""
|
364
349
|
|
365
350
|
model = 'gemini-1.5-flash-latest'
|
366
|
-
supported_modalities =
|
351
|
+
supported_modalities = (
|
352
|
+
vertexai.DOCUMENT_TYPES
|
353
|
+
+ vertexai.IMAGE_TYPES
|
354
|
+
+ vertexai.AUDIO_TYPES
|
355
|
+
+ vertexai.VIDEO_TYPES
|
356
|
+
)
|
367
357
|
|
368
358
|
|
369
359
|
class GeminiPro(GenAI):
|
@@ -376,7 +366,7 @@ class GeminiProVision(GenAI):
|
|
376
366
|
"""Gemini Pro vision model."""
|
377
367
|
|
378
368
|
model = 'gemini-pro-vision'
|
379
|
-
supported_modalities =
|
369
|
+
supported_modalities = vertexai.IMAGE_TYPES + vertexai.VIDEO_TYPES
|
380
370
|
|
381
371
|
|
382
372
|
class Palm2(GenAI):
|
langfun/core/llms/vertexai.py
CHANGED
@@ -343,7 +343,7 @@ class VertexAI(rest.REST):
|
|
343
343
|
return lf.AIMessage.from_chunks(chunks)
|
344
344
|
|
345
345
|
|
346
|
-
|
346
|
+
IMAGE_TYPES = [
|
347
347
|
'image/png',
|
348
348
|
'image/jpeg',
|
349
349
|
'image/webp',
|
@@ -351,7 +351,7 @@ _IMAGE_TYPES = [
|
|
351
351
|
'image/heif',
|
352
352
|
]
|
353
353
|
|
354
|
-
|
354
|
+
AUDIO_TYPES = [
|
355
355
|
'audio/aac',
|
356
356
|
'audio/flac',
|
357
357
|
'audio/mp3',
|
@@ -362,10 +362,10 @@ _AUDIO_TYPES = [
|
|
362
362
|
'audio/opus',
|
363
363
|
'audio/pcm',
|
364
364
|
'audio/wav',
|
365
|
-
'audio/webm'
|
365
|
+
'audio/webm',
|
366
366
|
]
|
367
367
|
|
368
|
-
|
368
|
+
VIDEO_TYPES = [
|
369
369
|
'video/mov',
|
370
370
|
'video/mpeg',
|
371
371
|
'video/mpegps',
|
@@ -375,9 +375,10 @@ _VIDEO_TYPES = [
|
|
375
375
|
'video/wmv',
|
376
376
|
'video/x-flv',
|
377
377
|
'video/3gpp',
|
378
|
+
'video/quicktime',
|
378
379
|
]
|
379
380
|
|
380
|
-
|
381
|
+
DOCUMENT_TYPES = [
|
381
382
|
'application/pdf',
|
382
383
|
'text/plain',
|
383
384
|
'text/csv',
|
@@ -391,8 +392,8 @@ _DOCUMENT_TYPES = [
|
|
391
392
|
class VertexAIGemini1_5(VertexAI): # pylint: disable=invalid-name
|
392
393
|
"""Vertex AI Gemini 1.5 model."""
|
393
394
|
|
394
|
-
supported_modalities: pg.typing.List(str).freeze(
|
395
|
-
|
395
|
+
supported_modalities: pg.typing.List(str).freeze( # pytype: disable=invalid-annotation
|
396
|
+
DOCUMENT_TYPES + IMAGE_TYPES + AUDIO_TYPES + VIDEO_TYPES
|
396
397
|
)
|
397
398
|
|
398
399
|
|
@@ -460,8 +461,8 @@ class VertexAIGeminiPro1Vision(VertexAI): # pylint: disable=invalid-name
|
|
460
461
|
"""Vertex AI Gemini 1.0 Pro Vision model."""
|
461
462
|
|
462
463
|
model = 'gemini-1.0-pro-vision'
|
463
|
-
supported_modalities: pg.typing.List(str).freeze(
|
464
|
-
|
464
|
+
supported_modalities: pg.typing.List(str).freeze( # pytype: disable=invalid-annotation
|
465
|
+
IMAGE_TYPES + VIDEO_TYPES
|
465
466
|
)
|
466
467
|
|
467
468
|
|
langfun/core/message.py
CHANGED
langfun/core/message_test.py
CHANGED
@@ -264,9 +264,9 @@ def query(
|
|
264
264
|
schema_lib.Schema.from_value(schema)
|
265
265
|
if schema not in (None, str) else None
|
266
266
|
),
|
267
|
-
output=pg.Ref(_result(output_message)),
|
268
267
|
lm=pg.Ref(lm),
|
269
268
|
examples=pg.Ref(examples) if examples else [],
|
269
|
+
lm_response=lf.AIMessage(output_message.text),
|
270
270
|
usage_summary=usage_summary,
|
271
271
|
)
|
272
272
|
for i, (tracker, include_child_scopes) in enumerate(trackers):
|
@@ -357,7 +357,7 @@ def _reward_fn(cls) -> Callable[
|
|
357
357
|
return _reward
|
358
358
|
|
359
359
|
|
360
|
-
class QueryInvocation(pg.Object):
|
360
|
+
class QueryInvocation(pg.Object, pg.views.HtmlTreeView.Extension):
|
361
361
|
"""A class to represent the invocation of `lf.query`."""
|
362
362
|
|
363
363
|
input: Annotated[
|
@@ -368,9 +368,9 @@ class QueryInvocation(pg.Object):
|
|
368
368
|
schema_lib.schema_spec(noneable=True),
|
369
369
|
'Schema of `lf.query`.'
|
370
370
|
]
|
371
|
-
|
372
|
-
|
373
|
-
'
|
371
|
+
lm_response: Annotated[
|
372
|
+
lf.Message,
|
373
|
+
'Raw LM response.'
|
374
374
|
]
|
375
375
|
lm: Annotated[
|
376
376
|
lf.LanguageModel,
|
@@ -385,6 +385,106 @@ class QueryInvocation(pg.Object):
|
|
385
385
|
'Usage summary for `lf.query`.'
|
386
386
|
]
|
387
387
|
|
388
|
+
@functools.cached_property
|
389
|
+
def lm_request(self) -> lf.Message:
|
390
|
+
return query_prompt(self.input, self.schema)
|
391
|
+
|
392
|
+
@functools.cached_property
|
393
|
+
def output(self) -> Any:
|
394
|
+
return query_output(self.lm_response, self.schema)
|
395
|
+
|
396
|
+
def _on_bound(self):
|
397
|
+
super()._on_bound()
|
398
|
+
self.__dict__.pop('lm_request', None)
|
399
|
+
self.__dict__.pop('output', None)
|
400
|
+
|
401
|
+
def _html_tree_view_summary(
|
402
|
+
self,
|
403
|
+
*,
|
404
|
+
view: pg.views.HtmlTreeView,
|
405
|
+
**kwargs: Any
|
406
|
+
) -> pg.Html | None:
|
407
|
+
return view.summary(
|
408
|
+
value=self,
|
409
|
+
title=pg.Html.element(
|
410
|
+
'div',
|
411
|
+
[
|
412
|
+
pg.views.html.controls.Label(
|
413
|
+
'lf.query',
|
414
|
+
css_classes=['query-invocation-type-name']
|
415
|
+
),
|
416
|
+
pg.views.html.controls.Badge(
|
417
|
+
f'lm={self.lm.model_id}',
|
418
|
+
pg.format(
|
419
|
+
self.lm,
|
420
|
+
verbose=False,
|
421
|
+
python_format=True,
|
422
|
+
hide_default_values=True
|
423
|
+
),
|
424
|
+
css_classes=['query-invocation-lm']
|
425
|
+
),
|
426
|
+
self.usage_summary.to_html(extra_flags=dict(as_badge=True))
|
427
|
+
],
|
428
|
+
css_classes=['query-invocation-title']
|
429
|
+
),
|
430
|
+
enable_summary_tooltip=False
|
431
|
+
)
|
432
|
+
|
433
|
+
def _html_tree_view_content(
|
434
|
+
self,
|
435
|
+
*,
|
436
|
+
view: pg.views.HtmlTreeView,
|
437
|
+
**kwargs: Any
|
438
|
+
) -> pg.Html:
|
439
|
+
return pg.views.html.controls.TabControl([
|
440
|
+
pg.views.html.controls.Tab(
|
441
|
+
'input',
|
442
|
+
pg.view(self.input, collapse_level=None),
|
443
|
+
),
|
444
|
+
pg.views.html.controls.Tab(
|
445
|
+
'schema',
|
446
|
+
pg.view(self.schema),
|
447
|
+
),
|
448
|
+
pg.views.html.controls.Tab(
|
449
|
+
'output',
|
450
|
+
pg.view(self.output, collapse_level=None),
|
451
|
+
),
|
452
|
+
pg.views.html.controls.Tab(
|
453
|
+
'lm_request',
|
454
|
+
pg.view(
|
455
|
+
self.lm_request,
|
456
|
+
extra_flags=dict(include_message_metadata=False),
|
457
|
+
),
|
458
|
+
),
|
459
|
+
pg.views.html.controls.Tab(
|
460
|
+
'lm_response',
|
461
|
+
pg.view(
|
462
|
+
self.lm_response,
|
463
|
+
extra_flags=dict(include_message_metadata=False)
|
464
|
+
),
|
465
|
+
),
|
466
|
+
], tab_position='top').to_html()
|
467
|
+
|
468
|
+
@classmethod
|
469
|
+
def _html_tree_view_css_styles(cls) -> list[str]:
|
470
|
+
return super()._html_tree_view_css_styles() + [
|
471
|
+
"""
|
472
|
+
.query-invocation-title {
|
473
|
+
display: inline-block;
|
474
|
+
font-weight: normal;
|
475
|
+
}
|
476
|
+
.query-invocation-type-name {
|
477
|
+
font-style: italic;
|
478
|
+
color: #888;
|
479
|
+
}
|
480
|
+
.query-invocation-lm.badge {
|
481
|
+
margin-left: 5px;
|
482
|
+
margin-right: 5px;
|
483
|
+
background-color: #fff0d6;
|
484
|
+
}
|
485
|
+
"""
|
486
|
+
]
|
487
|
+
|
388
488
|
|
389
489
|
@contextlib.contextmanager
|
390
490
|
def track_queries(
|
@@ -962,6 +962,18 @@ class QueryStructureJsonTest(unittest.TestCase):
|
|
962
962
|
)
|
963
963
|
|
964
964
|
|
965
|
+
class QueryInvocationTest(unittest.TestCase):
|
966
|
+
|
967
|
+
def test_to_html(self):
|
968
|
+
lm = fake.StaticSequence([
|
969
|
+
'Activity(description="hi")',
|
970
|
+
])
|
971
|
+
with prompting.track_queries() as queries:
|
972
|
+
prompting.query('foo', Activity, lm=lm)
|
973
|
+
|
974
|
+
self.assertIn('schema', queries[0].to_html_str())
|
975
|
+
|
976
|
+
|
965
977
|
class TrackQueriesTest(unittest.TestCase):
|
966
978
|
|
967
979
|
def test_include_child_scopes(self):
|
@@ -13,8 +13,8 @@ langfun/core/language_model_test.py,sha256=hnYhtw7GM_TbhgsJzHNYTaoDewUlPHpOVlI7x
|
|
13
13
|
langfun/core/logging.py,sha256=uslllP0RTGN223oro1m4nZZ0bFppcL07OwbFKm2iG6k,7519
|
14
14
|
langfun/core/logging_test.py,sha256=b5bPTSUoYeICATaO6I8dOVumodwRbxSp1Oz96Sf3KcE,6104
|
15
15
|
langfun/core/memory.py,sha256=f-asN1F7Vehgdn_fK84v73GrEUOxRtaW934keutTKjk,2416
|
16
|
-
langfun/core/message.py,sha256=
|
17
|
-
langfun/core/message_test.py,sha256=
|
16
|
+
langfun/core/message.py,sha256=tRHEx-oGt325epJ836C4LoRFVWdfV2_Xcg0Qwrau2rs,25716
|
17
|
+
langfun/core/message_test.py,sha256=v_BVCC5Ia-izwOBvKlw3waDJnKi0g4C68dc_cwlB1Vs,32611
|
18
18
|
langfun/core/modality.py,sha256=K8pUGuMpfWcOtVcXC_OqVjro1-RhHF6ddQni61DuYzM,4166
|
19
19
|
langfun/core/modality_test.py,sha256=7SwhixFME2Q1sIXRgJx97EZFiIyC31A9NVr6_nDtFv4,2441
|
20
20
|
langfun/core/natural_language.py,sha256=3ynSnaYQnjE60LIPK5fyMgdIjubnPYZwzGq4rWPeloE,1177
|
@@ -30,10 +30,10 @@ langfun/core/template_test.py,sha256=Qokz1hQFhRYaTZWBWGqvPJ0NXC9B9ennUpnRYHEf0hE
|
|
30
30
|
langfun/core/text_formatting.py,sha256=d7t9vaY6aCn1dkfkikpNYnBy5E_i93vHbfyDWFclGZU,5284
|
31
31
|
langfun/core/text_formatting_test.py,sha256=ck0Xzdd4YF4CtCUj7VE0GybfbAyKQ8p3xkM1FBGrqIk,2096
|
32
32
|
langfun/core/agentic/__init__.py,sha256=ndoDX0sAYsa3eVdXuu6nB-a-BH5TaK3urW6zAaFiyVs,1110
|
33
|
-
langfun/core/agentic/action.py,sha256=
|
33
|
+
langfun/core/agentic/action.py,sha256=jCVxTULwEi78ggg6lTDI7U1ejHzOvak_3FeAI-Td3Y0,26277
|
34
34
|
langfun/core/agentic/action_eval.py,sha256=ZtjTh34S7XPIUqandQ0YwAtzw-S7ofuZ7rRXnRbUMdQ,4424
|
35
35
|
langfun/core/agentic/action_eval_test.py,sha256=tRUkWmOE9p0rpNOq19xAY2oDEnYsEEykjg6sUpAwJk0,2832
|
36
|
-
langfun/core/agentic/action_test.py,sha256=
|
36
|
+
langfun/core/agentic/action_test.py,sha256=gVafU2akdrkEu2G4VaDDmXSYKNSkO1trghgcb1nDfIA,4591
|
37
37
|
langfun/core/coding/__init__.py,sha256=5utju_fwEsImaiftx4oXKl9FAM8p281k8-Esdh_-m1w,835
|
38
38
|
langfun/core/coding/python/__init__.py,sha256=MJ-vubliz-ebrZH3OBRKBwMi0S9-FrhGCp8YQLR6_I4,1776
|
39
39
|
langfun/core/coding/python/correction.py,sha256=WiBdoScL-6C___iA3Tg3vizuYtJWI-_4wy9zcMfVpj8,7020
|
@@ -79,14 +79,14 @@ langfun/core/eval/v2/reporting_test.py,sha256=JxffbUPWInUyLjo-AQVFrllga884Mdfm05
|
|
79
79
|
langfun/core/eval/v2/runners.py,sha256=kP6ZEg9L8M7fK03tOZYGqIjTKUzoJn8Hz_LXS7btFPQ,14335
|
80
80
|
langfun/core/eval/v2/runners_test.py,sha256=UeiUNygux_U6iGVG18rhp68ZE4hoWeoT6XsXvSjxNQg,11620
|
81
81
|
langfun/core/eval/v2/test_helper.py,sha256=pDpZTBnWRR5xjJv3Uy3NWEzArqlL8FTMOgeR4C53F5M,2348
|
82
|
-
langfun/core/llms/__init__.py,sha256=
|
83
|
-
langfun/core/llms/anthropic.py,sha256=
|
82
|
+
langfun/core/llms/__init__.py,sha256=Y3sTFM_V3l09WiRmjb-kQFHfqBAV23KH2JWJKMhZvMc,6278
|
83
|
+
langfun/core/llms/anthropic.py,sha256=afKZmdiLcosS_UEBlB8WKyf1K-zeXgwtPAx6ofg2Gww,13989
|
84
84
|
langfun/core/llms/anthropic_test.py,sha256=-2U4kc_pgBM7wqxu8RuxzyHPGww1EAWqKUvN4PW8Btw,8058
|
85
85
|
langfun/core/llms/compositional.py,sha256=csW_FLlgL-tpeyCOTVvfUQkMa_zCN5Y2I-YbSNuK27U,2872
|
86
86
|
langfun/core/llms/compositional_test.py,sha256=4eTnOer-DncRKGaIJW2ZQQMLnt5r2R0UIx_DYOvGAQo,2027
|
87
87
|
langfun/core/llms/fake.py,sha256=gCHBYBLvBCsC78HI1hpoqXCS-p1FMTgY1P1qh_sGBPk,3070
|
88
88
|
langfun/core/llms/fake_test.py,sha256=2h13qkwEz_JR0mtUDPxdAhQo7MueXaFSwsD2DIRDW9g,7653
|
89
|
-
langfun/core/llms/google_genai.py,sha256=
|
89
|
+
langfun/core/llms/google_genai.py,sha256=8gLOJ_o2T1uu84QU8RWDPzSlDNtidGkYQHWb1voKwCU,11263
|
90
90
|
langfun/core/llms/google_genai_test.py,sha256=zw14sgWmk0P_irHyb7vpPy1WAuLEE0PmyfiFElu03sA,7686
|
91
91
|
langfun/core/llms/groq.py,sha256=dCnR3eAECEKuKKAAj-PDTs8NRHl6CQPdf57m1f6a79U,10312
|
92
92
|
langfun/core/llms/groq_test.py,sha256=GYF_Qtq5S1H1TrKH38t6_lkdroqT7v-joYLDKnmS9e0,5274
|
@@ -96,7 +96,7 @@ langfun/core/llms/openai.py,sha256=l49v6RubfInvV0iG114AymTKNogTX4u4N-UFCeSgIxw,2
|
|
96
96
|
langfun/core/llms/openai_test.py,sha256=kOWa1nf-nJvtYY10REUw5wojh3ZgfU8tRaCZ8wUgJbA,16623
|
97
97
|
langfun/core/llms/rest.py,sha256=sWbYUV8S3SuOg9giq7xwD-xDRfaF7NP_ig7bI52-Rj4,3442
|
98
98
|
langfun/core/llms/rest_test.py,sha256=NZ3Nf0XQVpT9kLP5cBVo_yBHLI7vWTYhWQxYEJVMGs4,3472
|
99
|
-
langfun/core/llms/vertexai.py,sha256=
|
99
|
+
langfun/core/llms/vertexai.py,sha256=BkhRKnr20gIJvRL8G-KwTT7EM7v7L-pXkBkPeRkEFFY,14184
|
100
100
|
langfun/core/llms/vertexai_test.py,sha256=ffcA5yPecnQy_rhkuYAw_6o1iLW8AR8FgswmHt6aAys,6725
|
101
101
|
langfun/core/llms/cache/__init__.py,sha256=QAo3InUMDM_YpteNnVCSejI4zOsnjSMWKJKzkb3VY64,993
|
102
102
|
langfun/core/llms/cache/base.py,sha256=rt3zwmyw0y9jsSGW-ZbV1vAfLxQ7_3AVk0l2EySlse4,3918
|
@@ -129,8 +129,8 @@ langfun/core/structured/mapping.py,sha256=vLKH79UT-j0qkQdvqlQBO7SkXXuM-yr2Idm8_H
|
|
129
129
|
langfun/core/structured/mapping_test.py,sha256=bHm2ZCXBITq_G8Lvw_olFHeUUc4s_lGXZm9v9JhoPB4,9630
|
130
130
|
langfun/core/structured/parsing.py,sha256=D58wBWOC6r6DCJNychCDkiHPrsy1XJfBDCDDZtug00k,11765
|
131
131
|
langfun/core/structured/parsing_test.py,sha256=i0i090FVgM8ngGqYjds0hjEm1v7q4gv18k-z1kaNr7E,21467
|
132
|
-
langfun/core/structured/prompting.py,sha256=
|
133
|
-
langfun/core/structured/prompting_test.py,sha256=
|
132
|
+
langfun/core/structured/prompting.py,sha256=vvPZcB0OL_kQMwyCUe4r4Q77luHT_OwVX3DeILN0hNw,16564
|
133
|
+
langfun/core/structured/prompting_test.py,sha256=TFqerzK5RFlYyNL-X4wrhY-vOjF_XEpHX3nbSNuNKxg,29720
|
134
134
|
langfun/core/structured/schema.py,sha256=XHA-m_ENT_J0k8Q7WCiCL51xm7oXHOqskhO8RpPIurc,28174
|
135
135
|
langfun/core/structured/schema_generation.py,sha256=U3nRQsqmMZg_qIVDh2fiY3K4JLfsAL1LcKzIFP1iXFg,5316
|
136
136
|
langfun/core/structured/schema_generation_test.py,sha256=RM9s71kMNg2jTePwInkiW9fK1ACN37eyPeF8OII-0zw,2950
|
@@ -148,8 +148,8 @@ langfun/core/templates/demonstration.py,sha256=vCrgYubdZM5Umqcgp8NUVGXgr4P_c-fik
|
|
148
148
|
langfun/core/templates/demonstration_test.py,sha256=SafcDQ0WgI7pw05EmPI2S4v1t3ABKzup8jReCljHeK4,2162
|
149
149
|
langfun/core/templates/selfplay.py,sha256=yhgrJbiYwq47TgzThmHrDQTF4nDrTI09CWGhuQPNv-s,2273
|
150
150
|
langfun/core/templates/selfplay_test.py,sha256=Ot__1P1M8oJfoTp-M9-PQ6HUXqZKyMwvZ5f7yQ3yfyM,2326
|
151
|
-
langfun-0.1.2.
|
152
|
-
langfun-0.1.2.
|
153
|
-
langfun-0.1.2.
|
154
|
-
langfun-0.1.2.
|
155
|
-
langfun-0.1.2.
|
151
|
+
langfun-0.1.2.dev202412100804.dist-info/LICENSE,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
|
152
|
+
langfun-0.1.2.dev202412100804.dist-info/METADATA,sha256=IcDza3RsE6fuifE64s71Jo-T4LoROCzQ3mYHo8NCNko,8281
|
153
|
+
langfun-0.1.2.dev202412100804.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
154
|
+
langfun-0.1.2.dev202412100804.dist-info/top_level.txt,sha256=RhlEkHxs1qtzmmtWSwYoLVJAc1YrbPtxQ52uh8Z9VvY,8
|
155
|
+
langfun-0.1.2.dev202412100804.dist-info/RECORD,,
|
File without changes
|
File without changes
|
{langfun-0.1.2.dev202412080804.dist-info → langfun-0.1.2.dev202412100804.dist-info}/top_level.txt
RENAMED
File without changes
|