langfun 0.1.2.dev202412090805__py3-none-any.whl → 0.1.2.dev202412130804__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 +692 -138
- langfun/core/agentic/action_test.py +78 -42
- langfun/core/eval/v2/evaluation.py +3 -0
- langfun/core/eval/v2/experiment.py +27 -0
- langfun/core/eval/v2/experiment_test.py +11 -0
- langfun/core/llms/__init__.py +5 -1
- langfun/core/llms/anthropic.py +1 -1
- langfun/core/llms/google_genai.py +47 -44
- langfun/core/llms/vertexai.py +38 -11
- langfun/core/message.py +1 -2
- langfun/core/message_test.py +1 -2
- langfun/core/structured/prompting.py +140 -5
- langfun/core/structured/prompting_test.py +13 -0
- langfun/core/structured/schema.py +1 -1
- langfun/core/template.py +23 -37
- langfun/core/template_test.py +6 -26
- {langfun-0.1.2.dev202412090805.dist-info → langfun-0.1.2.dev202412130804.dist-info}/METADATA +1 -1
- {langfun-0.1.2.dev202412090805.dist-info → langfun-0.1.2.dev202412130804.dist-info}/RECORD +21 -21
- {langfun-0.1.2.dev202412090805.dist-info → langfun-0.1.2.dev202412130804.dist-info}/LICENSE +0 -0
- {langfun-0.1.2.dev202412090805.dist-info → langfun-0.1.2.dev202412130804.dist-info}/WHEEL +0 -0
- {langfun-0.1.2.dev202412090805.dist-info → langfun-0.1.2.dev202412130804.dist-info}/top_level.txt +0 -0
@@ -15,6 +15,7 @@
|
|
15
15
|
|
16
16
|
import contextlib
|
17
17
|
import functools
|
18
|
+
import time
|
18
19
|
from typing import Annotated, Any, Callable, Iterator, Type, Union
|
19
20
|
|
20
21
|
import langfun.core as lf
|
@@ -221,6 +222,7 @@ def query(
|
|
221
222
|
query_input = schema_lib.mark_missing(prompt)
|
222
223
|
|
223
224
|
with lf.track_usages() as usage_summary:
|
225
|
+
start_time = time.time()
|
224
226
|
if schema in (None, str):
|
225
227
|
# Query with natural language output.
|
226
228
|
output_message = lf.LangFunc.from_value(query_input, **kwargs)(
|
@@ -250,6 +252,7 @@ def query(
|
|
250
252
|
cache_seed=cache_seed,
|
251
253
|
skip_lm=skip_lm,
|
252
254
|
)
|
255
|
+
end_time = time.time()
|
253
256
|
|
254
257
|
def _result(message: lf.Message):
|
255
258
|
return message.text if schema in (None, str) else message.result
|
@@ -264,10 +267,12 @@ def query(
|
|
264
267
|
schema_lib.Schema.from_value(schema)
|
265
268
|
if schema not in (None, str) else None
|
266
269
|
),
|
267
|
-
output=pg.Ref(_result(output_message)),
|
268
270
|
lm=pg.Ref(lm),
|
269
271
|
examples=pg.Ref(examples) if examples else [],
|
272
|
+
lm_response=lf.AIMessage(output_message.text),
|
270
273
|
usage_summary=usage_summary,
|
274
|
+
start_time=start_time,
|
275
|
+
end_time=end_time,
|
271
276
|
)
|
272
277
|
for i, (tracker, include_child_scopes) in enumerate(trackers):
|
273
278
|
if i == 0 or include_child_scopes:
|
@@ -357,7 +362,7 @@ def _reward_fn(cls) -> Callable[
|
|
357
362
|
return _reward
|
358
363
|
|
359
364
|
|
360
|
-
class QueryInvocation(pg.Object):
|
365
|
+
class QueryInvocation(pg.Object, pg.views.HtmlTreeView.Extension):
|
361
366
|
"""A class to represent the invocation of `lf.query`."""
|
362
367
|
|
363
368
|
input: Annotated[
|
@@ -368,9 +373,9 @@ class QueryInvocation(pg.Object):
|
|
368
373
|
schema_lib.schema_spec(noneable=True),
|
369
374
|
'Schema of `lf.query`.'
|
370
375
|
]
|
371
|
-
|
372
|
-
|
373
|
-
'
|
376
|
+
lm_response: Annotated[
|
377
|
+
lf.Message,
|
378
|
+
'Raw LM response.'
|
374
379
|
]
|
375
380
|
lm: Annotated[
|
376
381
|
lf.LanguageModel,
|
@@ -384,6 +389,136 @@ class QueryInvocation(pg.Object):
|
|
384
389
|
lf.UsageSummary,
|
385
390
|
'Usage summary for `lf.query`.'
|
386
391
|
]
|
392
|
+
start_time: Annotated[
|
393
|
+
float,
|
394
|
+
'Start time of query.'
|
395
|
+
]
|
396
|
+
end_time: Annotated[
|
397
|
+
float,
|
398
|
+
'End time of query.'
|
399
|
+
]
|
400
|
+
|
401
|
+
@functools.cached_property
|
402
|
+
def lm_request(self) -> lf.Message:
|
403
|
+
return query_prompt(self.input, self.schema)
|
404
|
+
|
405
|
+
@functools.cached_property
|
406
|
+
def output(self) -> Any:
|
407
|
+
return query_output(self.lm_response, self.schema)
|
408
|
+
|
409
|
+
@property
|
410
|
+
def elapse(self) -> float:
|
411
|
+
"""Returns query elapse in seconds."""
|
412
|
+
return self.end_time - self.start_time
|
413
|
+
|
414
|
+
def _on_bound(self):
|
415
|
+
super()._on_bound()
|
416
|
+
self.__dict__.pop('lm_request', None)
|
417
|
+
self.__dict__.pop('output', None)
|
418
|
+
|
419
|
+
def _html_tree_view_summary(
|
420
|
+
self,
|
421
|
+
*,
|
422
|
+
view: pg.views.HtmlTreeView,
|
423
|
+
**kwargs: Any
|
424
|
+
) -> pg.Html | None:
|
425
|
+
kwargs.pop('title', None)
|
426
|
+
kwargs.pop('enable_summary_tooltip', None)
|
427
|
+
return view.summary(
|
428
|
+
value=self,
|
429
|
+
title=pg.Html.element(
|
430
|
+
'div',
|
431
|
+
[
|
432
|
+
pg.views.html.controls.Label(
|
433
|
+
'lf.query',
|
434
|
+
css_classes=['query-invocation-type-name']
|
435
|
+
),
|
436
|
+
pg.views.html.controls.Badge(
|
437
|
+
f'lm={self.lm.model_id}',
|
438
|
+
pg.format(
|
439
|
+
self.lm,
|
440
|
+
verbose=False,
|
441
|
+
python_format=True,
|
442
|
+
hide_default_values=True
|
443
|
+
),
|
444
|
+
css_classes=['query-invocation-lm']
|
445
|
+
),
|
446
|
+
pg.views.html.controls.Badge(
|
447
|
+
f'{int(self.elapse)} seconds',
|
448
|
+
css_classes=['query-invocation-time']
|
449
|
+
),
|
450
|
+
self.usage_summary.to_html(extra_flags=dict(as_badge=True))
|
451
|
+
],
|
452
|
+
css_classes=['query-invocation-title']
|
453
|
+
),
|
454
|
+
enable_summary_tooltip=False,
|
455
|
+
**kwargs
|
456
|
+
)
|
457
|
+
|
458
|
+
def _html_tree_view_content(
|
459
|
+
self,
|
460
|
+
*,
|
461
|
+
view: pg.views.HtmlTreeView,
|
462
|
+
**kwargs: Any
|
463
|
+
) -> pg.Html:
|
464
|
+
return pg.views.html.controls.TabControl([
|
465
|
+
pg.views.html.controls.Tab(
|
466
|
+
'input',
|
467
|
+
pg.view(self.input, collapse_level=None),
|
468
|
+
),
|
469
|
+
pg.views.html.controls.Tab(
|
470
|
+
'output',
|
471
|
+
pg.view(self.output, collapse_level=None),
|
472
|
+
),
|
473
|
+
pg.views.html.controls.Tab(
|
474
|
+
'schema',
|
475
|
+
pg.view(self.schema),
|
476
|
+
),
|
477
|
+
pg.views.html.controls.Tab(
|
478
|
+
'lm_request',
|
479
|
+
pg.view(
|
480
|
+
self.lm_request,
|
481
|
+
extra_flags=dict(include_message_metadata=False),
|
482
|
+
),
|
483
|
+
),
|
484
|
+
pg.views.html.controls.Tab(
|
485
|
+
'lm_response',
|
486
|
+
pg.view(
|
487
|
+
self.lm_response,
|
488
|
+
extra_flags=dict(include_message_metadata=False)
|
489
|
+
),
|
490
|
+
),
|
491
|
+
], tab_position='top', selected=1).to_html()
|
492
|
+
|
493
|
+
@classmethod
|
494
|
+
def _html_tree_view_css_styles(cls) -> list[str]:
|
495
|
+
return super()._html_tree_view_css_styles() + [
|
496
|
+
"""
|
497
|
+
.query-invocation-title {
|
498
|
+
display: inline-block;
|
499
|
+
font-weight: normal;
|
500
|
+
}
|
501
|
+
.query-invocation-type-name {
|
502
|
+
color: #888;
|
503
|
+
}
|
504
|
+
.query-invocation-lm.badge {
|
505
|
+
margin-left: 5px;
|
506
|
+
margin-right: 5px;
|
507
|
+
color: white;
|
508
|
+
background-color: mediumslateblue;
|
509
|
+
}
|
510
|
+
.query-invocation-time.badge {
|
511
|
+
margin-left: 5px;
|
512
|
+
border-radius: 0px;
|
513
|
+
font-weight: bold;
|
514
|
+
background-color: aliceblue;
|
515
|
+
}
|
516
|
+
.query-invocation-title .usage-summary.label {
|
517
|
+
border-radius: 0px;
|
518
|
+
color: #AAA;
|
519
|
+
}
|
520
|
+
"""
|
521
|
+
]
|
387
522
|
|
388
523
|
|
389
524
|
@contextlib.contextmanager
|
@@ -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):
|
@@ -984,6 +996,7 @@ class TrackQueriesTest(unittest.TestCase):
|
|
984
996
|
self.assertEqual(queries[1].schema.spec.cls, Activity)
|
985
997
|
self.assertTrue(pg.eq(queries[1].output, Activity(description='hi')))
|
986
998
|
self.assertIs(queries[1].lm, lm)
|
999
|
+
self.assertGreater(queries[0].elapse, 0)
|
987
1000
|
self.assertGreater(queries[0].usage_summary.total.total_tokens, 0)
|
988
1001
|
self.assertGreater(queries[1].usage_summary.total.total_tokens, 0)
|
989
1002
|
|
langfun/core/template.py
CHANGED
@@ -552,38 +552,33 @@ class Template(
|
|
552
552
|
)
|
553
553
|
|
554
554
|
def render_fields():
|
555
|
-
return
|
556
|
-
|
557
|
-
|
558
|
-
|
559
|
-
|
560
|
-
|
561
|
-
|
562
|
-
|
563
|
-
|
564
|
-
|
565
|
-
|
566
|
-
|
567
|
-
|
568
|
-
|
569
|
-
|
570
|
-
**view.get_passthrough_kwargs(
|
571
|
-
remove=['exclude_keys'],
|
572
|
-
**kwargs,
|
573
|
-
)
|
574
|
-
),
|
575
|
-
],
|
576
|
-
css_classes=['template-fields'],
|
555
|
+
return view.complex_value(
|
556
|
+
{k: v for k, v in self.sym_items()},
|
557
|
+
name='fields',
|
558
|
+
root_path=root_path,
|
559
|
+
parent=self,
|
560
|
+
exclude_keys=['template_str', 'clean'],
|
561
|
+
collapse_level=max(
|
562
|
+
collapse_template_vars_level, collapse_level
|
563
|
+
) if collapse_level is not None else None,
|
564
|
+
extra_flags=extra_flags,
|
565
|
+
debug=debug,
|
566
|
+
**view.get_passthrough_kwargs(
|
567
|
+
remove=['exclude_keys'],
|
568
|
+
**kwargs,
|
569
|
+
)
|
577
570
|
)
|
578
571
|
|
579
|
-
return pg.
|
580
|
-
|
581
|
-
|
572
|
+
return pg.views.html.controls.TabControl([
|
573
|
+
pg.views.html.controls.Tab(
|
574
|
+
'template_str',
|
582
575
|
render_template_str(),
|
576
|
+
),
|
577
|
+
pg.views.html.controls.Tab(
|
578
|
+
'variables',
|
583
579
|
render_fields(),
|
584
|
-
|
585
|
-
|
586
|
-
)
|
580
|
+
),
|
581
|
+
], selected=1)
|
587
582
|
|
588
583
|
@classmethod
|
589
584
|
def _html_tree_view_css_styles(cls) -> list[str]:
|
@@ -601,15 +596,6 @@ class Template(
|
|
601
596
|
background-color: #EEE;
|
602
597
|
color: #cc2986;
|
603
598
|
}
|
604
|
-
.template-fields {
|
605
|
-
margin: 0px 0px 5px 0px;
|
606
|
-
border: 1px solid #EEE;
|
607
|
-
padding: 5px;
|
608
|
-
}
|
609
|
-
.template-fields > legend {
|
610
|
-
font-size: 0.8em;
|
611
|
-
margin: 5px 0px 5px 0px;
|
612
|
-
}
|
613
599
|
"""
|
614
600
|
]
|
615
601
|
|
langfun/core/template_test.py
CHANGED
@@ -555,13 +555,6 @@ class TemplateRenderEventTest(unittest.TestCase):
|
|
555
555
|
|
556
556
|
class HtmlTest(unittest.TestCase):
|
557
557
|
|
558
|
-
def assert_html_content(self, html, expected):
|
559
|
-
expected = inspect.cleandoc(expected).strip()
|
560
|
-
actual = html.content.strip()
|
561
|
-
if actual != expected:
|
562
|
-
print(actual)
|
563
|
-
self.assertEqual(actual, expected)
|
564
|
-
|
565
558
|
def test_html(self):
|
566
559
|
|
567
560
|
class Foo(Template):
|
@@ -594,36 +587,23 @@ class HtmlTest(unittest.TestCase):
|
|
594
587
|
background-color: #EEE;
|
595
588
|
color: #cc2986;
|
596
589
|
}
|
597
|
-
.template-fields {
|
598
|
-
margin: 0px 0px 5px 0px;
|
599
|
-
border: 1px solid #EEE;
|
600
|
-
padding: 5px;
|
601
|
-
}
|
602
|
-
.template-fields > legend {
|
603
|
-
font-size: 0.8em;
|
604
|
-
margin: 5px 0px 5px 0px;
|
605
|
-
}
|
606
590
|
"""
|
607
591
|
),
|
608
592
|
Foo(x=1, y=2).to_html().style_section,
|
609
593
|
)
|
610
|
-
self.
|
594
|
+
self.assertIn(
|
595
|
+
'template-str',
|
611
596
|
Foo(x=Bar('{{y}} + {{z}}'), y=1).to_html(
|
612
597
|
enable_summary_tooltip=False,
|
613
|
-
),
|
614
|
-
"""
|
615
|
-
<details open class="pyglove foo lf-template"><summary><div class="summary-title lf-template">Foo(...)</div></summary><div class="complex_value"><div class="template-str"><span>{{x}} + {{y}} = ?</span></div><fieldset class="template-fields"><legend>Template Variables</legend><div class="complex-value foo"><details class="pyglove bar lf-template"><summary><div class="summary-name lf-template">x<span class="tooltip lf-template">x</span></div><div class="summary-title lf-template">Bar(...)</div></summary><div class="complex_value"><div class="template-str"><span>{{y}} + {{z}}</span></div><fieldset class="template-fields"><legend>Template Variables</legend><div class="complex-value bar"><details open class="pyglove contextual-attribute"><summary><div class="summary-name">y<span class="tooltip">x.y</span></div><div class="summary-title">ContextualAttribute(...)</div></summary><span class="simple-value int">1</span></details><details open class="pyglove contextual-attribute"><summary><div class="summary-name">z<span class="tooltip">x.z</span></div><div class="summary-title">ContextualAttribute(...)</div></summary><div class="unavailable-contextual">(not available)</div></details></div></fieldset></div></details><details open class="pyglove int"><summary><div class="summary-name">y<span class="tooltip">y</span></div><div class="summary-title">int</div></summary><span class="simple-value int">1</span></details></div></fieldset></div></details>
|
616
|
-
"""
|
598
|
+
).content,
|
617
599
|
)
|
618
|
-
self.
|
600
|
+
self.assertIn(
|
601
|
+
'template-str',
|
619
602
|
Foo(x=Bar('{{y}} + {{z}}'), y=1).to_html(
|
620
603
|
enable_summary_tooltip=False,
|
621
604
|
collapse_level=0,
|
622
605
|
key_style='label',
|
623
|
-
),
|
624
|
-
"""
|
625
|
-
<details class="pyglove foo lf-template"><summary><div class="summary-title lf-template">Foo(...)</div></summary><div class="complex_value"><div class="template-str"><span>{{x}} + {{y}} = ?</span></div><fieldset class="template-fields"><legend>Template Variables</legend><div class="complex-value foo"><table><tr><td><span class="object-key str">x</span><span class="tooltip">x</span></td><td><details class="pyglove bar lf-template"><summary><div class="summary-title lf-template">Bar(...)</div></summary><div class="complex_value"><div class="template-str"><span>{{y}} + {{z}}</span></div><fieldset class="template-fields"><legend>Template Variables</legend><div class="complex-value bar"><table><tr><td><span class="object-key str">y</span><span class="tooltip">x.y</span></td><td><details open class="pyglove contextual-attribute"><summary><div class="summary-title">ContextualAttribute(...)</div></summary><span class="simple-value int">1</span></details></td></tr><tr><td><span class="object-key str">z</span><span class="tooltip">x.z</span></td><td><details open class="pyglove contextual-attribute"><summary><div class="summary-title">ContextualAttribute(...)</div></summary><div class="unavailable-contextual">(not available)</div></details></td></tr></table></div></fieldset></div></details></td></tr><tr><td><span class="object-key str">y</span><span class="tooltip">y</span></td><td><span class="simple-value int">1</span></td></tr></table></div></fieldset></div></details>
|
626
|
-
"""
|
606
|
+
).content,
|
627
607
|
)
|
628
608
|
|
629
609
|
|
@@ -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=16oiMpg9O9VKrgpfrvJrfvga3n3FzUuD_zdWb9nvSWA,25686
|
17
|
+
langfun/core/message_test.py,sha256=jtZoNBNbA99i2fjoKg5vTRgoUe84J4MH8ZMGakGmTHs,32577
|
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
|
@@ -25,15 +25,15 @@ langfun/core/sampling.py,sha256=SCnS5PFJWNVxSKvSkSCNRUmruvScun8UcNN4gafuXcw,5866
|
|
25
25
|
langfun/core/sampling_test.py,sha256=U7PANpMsl9E_pa4_Y4FzesSjcwg-u-LKHGCWSgv-8FY,3663
|
26
26
|
langfun/core/subscription.py,sha256=euawEuSZP-BHydaT-AQpfYFL0m5pWPGcW0upFhrojqc,10930
|
27
27
|
langfun/core/subscription_test.py,sha256=Y4ZdbZEwm83YNZBxHff0QR4QUa4rdaNXA3_jfIcArBo,8717
|
28
|
-
langfun/core/template.py,sha256=
|
29
|
-
langfun/core/template_test.py,sha256=
|
28
|
+
langfun/core/template.py,sha256=jNhYSrbLIn9kZOa03w5QZbyjgfnzJzE_ZrrMvvWY4t4,24929
|
29
|
+
langfun/core/template_test.py,sha256=g7x4mgNIAXEEj-4W1D5whGfl5YikLEQoylKPzaeDomk,17069
|
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=yW5-2NRHIrQmmQEYmL83aIdSwaRfUez9mqCbME_aBWQ,25391
|
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=Gu7P5XQvzqbKawn2jjyTpWaARzzhzO04KkC1TuBnUnw,4612
|
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
|
@@ -60,12 +60,12 @@ langfun/core/eval/scoring_test.py,sha256=O8olHbrUEg60gMxwOkWzKBJZpZoUlmVnBANX5Se
|
|
60
60
|
langfun/core/eval/v2/__init__.py,sha256=XMpkKjd_vL_qzCQYPAwR1NNO0T_Zo5j4kP3eYL-EJLc,1428
|
61
61
|
langfun/core/eval/v2/checkpointing.py,sha256=AhChb5U0fTd0NmDHaIaVE9qJ8zFEe7Lhq7KjIt1D2pQ,3766
|
62
62
|
langfun/core/eval/v2/checkpointing_test.py,sha256=xU5asikwUn-rCmNd93ssvT6gDiKvvWogYKQa0r_TqOM,3046
|
63
|
-
langfun/core/eval/v2/evaluation.py,sha256=
|
63
|
+
langfun/core/eval/v2/evaluation.py,sha256=h_AWRUSKhEs-bHLBgqo-GeBYXluD5bPbAqypRW0ajfA,19441
|
64
64
|
langfun/core/eval/v2/evaluation_test.py,sha256=hh6L2HhQPQ6NBv1pXKcNkYraNcV9MLuJ--69t9jbmaI,5846
|
65
65
|
langfun/core/eval/v2/example.py,sha256=fURrvdNmMsVMqoEErcsmLmC6Xq3ny16dYsnLH8HVlcY,9626
|
66
66
|
langfun/core/eval/v2/example_test.py,sha256=WcJmU7IQQXvjFia63mokySC4CqxzVL9Wso1sC5F0YK8,3032
|
67
|
-
langfun/core/eval/v2/experiment.py,sha256=
|
68
|
-
langfun/core/eval/v2/experiment_test.py,sha256=
|
67
|
+
langfun/core/eval/v2/experiment.py,sha256=0JBGckJ93aqSdffpJPDVPy_I5T2BXscghTxiglHzJWo,29556
|
68
|
+
langfun/core/eval/v2/experiment_test.py,sha256=zSMHYqC9cA0k61U71pCSYTAJ6yK2_b6Dml5btc-bKzQ,9133
|
69
69
|
langfun/core/eval/v2/metric_values.py,sha256=_B905bC-jxrYPLSEcP2M8MaHZOVMz_bVrUw8YC4arCE,4660
|
70
70
|
langfun/core/eval/v2/metric_values_test.py,sha256=ab2oF_HsIwrSy459108ggyjgefHSPn8UVILR4dRwx14,2634
|
71
71
|
langfun/core/eval/v2/metrics.py,sha256=bl8i6u-ZHRBz4hAc3LzsZ2Dc7ZRQcuTYeUhhH-GxfF0,10628
|
@@ -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=lWXKjGHv66ShG7AE_Bc4QM7SDTxJdfoQMn3PF0lr0sU,6461
|
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=AAYOsSyeNIfHduIL9ZBzLhA8_acZUDMzHhS7AwUbOlM,11603
|
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=adUTByiuiTHBQ31tM_EXPUWIyUwo3zqyYIe9UILAFDE,14981
|
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,9 +129,9 @@ 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=
|
134
|
-
langfun/core/structured/schema.py,sha256=
|
132
|
+
langfun/core/structured/prompting.py,sha256=ceZQgK00rlnDxFEPKq4O61zJs6u-W_mggT02bODqBSg,17522
|
133
|
+
langfun/core/structured/prompting_test.py,sha256=fHJuBli4dryQIrg_HmU7gMWSIOzHuYM_4xT3m84haGs,29765
|
134
|
+
langfun/core/structured/schema.py,sha256=_T8WIDdpvWXlZVPLVgKYH9TvoM9gK11m3f0b2nImQRM,28190
|
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
|
137
137
|
langfun/core/structured/schema_test.py,sha256=RjYhwTgktQgyqAjzLvo967nTiIK9KWgP-aNGg4e7ihE,25258
|
@@ -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.dev202412130804.dist-info/LICENSE,sha256=WNHhf_5RCaeuKWyq_K39vmp9F28LxKsB4SpomwSZ2L0,11357
|
152
|
+
langfun-0.1.2.dev202412130804.dist-info/METADATA,sha256=CKqDMChv6guUECwAsOYKWNN95mZSylJOTnBA-c8xhuE,8281
|
153
|
+
langfun-0.1.2.dev202412130804.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
154
|
+
langfun-0.1.2.dev202412130804.dist-info/top_level.txt,sha256=RhlEkHxs1qtzmmtWSwYoLVJAc1YrbPtxQ52uh8Z9VvY,8
|
155
|
+
langfun-0.1.2.dev202412130804.dist-info/RECORD,,
|
File without changes
|
File without changes
|
{langfun-0.1.2.dev202412090805.dist-info → langfun-0.1.2.dev202412130804.dist-info}/top_level.txt
RENAMED
File without changes
|