• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

deepset-ai / haystack / 15825051859

23 Jun 2025 01:05PM UTC coverage: 90.176% (-0.005%) from 90.181%
15825051859

Pull #9536

github

web-flow
Merge 0408d779d into 556dcc9e4
Pull Request #9536: feat: Add `finish_reason` field to `StreamingChunk`

11575 of 12836 relevant lines covered (90.18%)

0.9 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

23.08
haystack/dataclasses/__init__.py
1
# SPDX-FileCopyrightText: 2022-present deepset GmbH <info@deepset.ai>
2
#
3
# SPDX-License-Identifier: Apache-2.0
4

5
import sys
1✔
6
from typing import TYPE_CHECKING
1✔
7

8
from lazy_imports import LazyImporter
1✔
9

10
_import_structure = {
1✔
11
    "answer": ["Answer", "ExtractedAnswer", "GeneratedAnswer"],
12
    "byte_stream": ["ByteStream"],
13
    "chat_message": ["ChatMessage", "ChatRole", "TextContent", "ToolCall", "ToolCallResult"],
14
    "document": ["Document"],
15
    "sparse_embedding": ["SparseEmbedding"],
16
    "state": ["State"],
17
    "streaming_chunk": [
18
        "AsyncStreamingCallbackT",
19
        "ComponentInfo",
20
        "FinishReason",
21
        "StreamingCallbackT",
22
        "StreamingChunk",
23
        "SyncStreamingCallbackT",
24
        "ToolCallDelta",
25
        "select_streaming_callback",
26
    ],
27
}
28

29
if TYPE_CHECKING:
1✔
30
    from .answer import Answer as Answer
×
31
    from .answer import ExtractedAnswer as ExtractedAnswer
×
32
    from .answer import GeneratedAnswer as GeneratedAnswer
×
33
    from .byte_stream import ByteStream as ByteStream
×
34
    from .chat_message import ChatMessage as ChatMessage
×
35
    from .chat_message import ChatRole as ChatRole
×
36
    from .chat_message import TextContent as TextContent
×
37
    from .chat_message import ToolCall as ToolCall
×
38
    from .chat_message import ToolCallResult as ToolCallResult
×
39
    from .document import Document as Document
×
40
    from .sparse_embedding import SparseEmbedding as SparseEmbedding
×
41
    from .state import State as State
×
42
    from .streaming_chunk import AsyncStreamingCallbackT as AsyncStreamingCallbackT
×
43
    from .streaming_chunk import ComponentInfo as ComponentInfo
×
44
    from .streaming_chunk import FinishReason as FinishReason
×
45
    from .streaming_chunk import StreamingCallbackT as StreamingCallbackT
×
46
    from .streaming_chunk import StreamingChunk as StreamingChunk
×
47
    from .streaming_chunk import SyncStreamingCallbackT as SyncStreamingCallbackT
×
48
    from .streaming_chunk import ToolCallDelta as ToolCallDelta
×
49
    from .streaming_chunk import select_streaming_callback as select_streaming_callback
×
50
else:
51
    sys.modules[__name__] = LazyImporter(name=__name__, module_file=__file__, import_structure=_import_structure)
1✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc