blib/lib/Langertha/Stream/Chunk.pm

filter: Statementstmt 100% 20 / 20 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 2 / 2 Podpod n/a totaltotal 100% 22 / 22 CC 1 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« blib/lib/Langertha/Role/ToolResultPDF.pm ↑ Summary blib/lib/LangerthaX.pm »
1 package Langertha::Stream::Chunk;
2 # ABSTRACT: Represents a single chunk from a streaming response
3 196 our $VERSION = '0.505';
4 196 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 196 ▶use Langertha::ToolCall;
Subroutine BEGIN: called CC=1 SCAR=0.0
6  
7  
8 196 has content => (
9 is => 'ro',
10 isa => 'Str',
11 required => 1,
12 );
13  
14  
15 196 has raw => (
16 is => 'ro',
17 isa => 'HashRef',
18 predicate => 'has_raw',
19 );
20  
21  
22 196 has is_final => (
23 is => 'ro',
24 isa => 'Bool',
25 default => 0,
26 );
27  
28  
29 196 has model => (
30 is => 'ro',
31 isa => 'Str',
32 predicate => 'has_model',
33 );
34  
35  
36 196 has finish_reason => (
37 is => 'ro',
38 isa => 'Maybe[Str]',
39 predicate => 'has_finish_reason',
40 );
41  
42  
43 196 has usage => (
44 is => 'ro',
45 isa => 'Maybe[HashRef]',
46 predicate => 'has_usage',
47 );
48  
49 196 has cached_tokens => (
50 is => 'ro',
51 isa => 'Maybe[Int]',
52 predicate => 'has_cached_tokens',
53 );
54  
55 196 has tool_calls => (
56 is => 'ro',
57 isa => 'Maybe[ArrayRef[Langertha::ToolCall]]',
58 predicate => 'has_tool_calls',
59 );
60  
61  
62 196 has citations => (
63 is => 'ro',
64 isa => 'Maybe[ArrayRef]',
65 predicate => 'has_citations',
66 );
67  
68  
69 196 has thinking => (
70 is => 'ro',
71 isa => 'Maybe[Str]',
72 predicate => 'has_thinking',
73 );
74  
75  
76 196 has refusal => (
77 is => 'ro',
78 isa => 'Maybe[Str]',
79 predicate => 'has_refusal',
80 );
81  
82  
83  
84  
85  
86 196 __PACKAGE__->meta->make_immutable;
87  
88 196 1;
89  
90 __END__
« blib/lib/Langertha/Role/ToolResultPDF.pm ↑ Summary blib/lib/LangerthaX.pm »