firecrawl-sdk 1.4.0 → 1.4.1

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 60a3360b0facad41a4d3c0a1a94e520f675ce5b6f72487665ead37f1b988de50
4
- data.tar.gz: 51ced5462346c81d02327786e5022cd5789fed14940346e231c8619eb5b686b6
3
+ metadata.gz: 70b6cc0e7e9b3713301a01f3e016cc4d1d8c5c9ef710a4070a89c016d6618d94
4
+ data.tar.gz: 56ac98b6d8c495e2b449484441f31540435066b8c0be35a456e0faad609df2e8
5
5
  SHA512:
6
- metadata.gz: 2e7a56e1fc2bd3b56b88337047f7c655c7ac78e6d43de94f4ee89c9b67701be95b45232d17ce6383023bd3d59199388012257c32d36c10c61823b02f5574f931
7
- data.tar.gz: f2be762f47550bfa3bda7e7d8e7833b404b30d5447558893bc36ffe5de13953cc02bc00efe09d51f91eec9c1715701275e50336d154d2c47f4d5121a424aeb87
6
+ metadata.gz: 46deb97a266f954bd2f9f32b4c100e4bcfa7a15ef408f93df502665431bd4f88656d53f8d02d3bc19aa6dd07ea7cbc4f3b1a5a5db9b81cafcfc0b3a140bb6dd6
7
+ data.tar.gz: a992a108c3e46e242d584a47f9558ce18dc870c378560413b7cdad3064707f134d0971520cfe17568824f7a80c278f46bf94fd420e1d58824866a73066228f39
@@ -6,7 +6,8 @@ module Firecrawl
6
6
  class Document
7
7
  attr_reader :markdown, :html, :raw_html, :json, :summary,
8
8
  :metadata, :links, :images, :screenshot, :audio,
9
- :attributes, :actions, :warning, :change_tracking, :branding
9
+ :attributes, :actions, :answer, :highlights, :warning,
10
+ :change_tracking, :branding
10
11
 
11
12
  def initialize(data)
12
13
  @markdown = data["markdown"]
@@ -21,6 +22,8 @@ module Firecrawl
21
22
  @audio = data["audio"]
22
23
  @attributes = data["attributes"]
23
24
  @actions = data["actions"]
25
+ @answer = data["answer"]
26
+ @highlights = data["highlights"]
24
27
  @warning = data["warning"]
25
28
  @change_tracking = data["changeTracking"]
26
29
  @branding = data["branding"]
@@ -2,7 +2,47 @@
2
2
 
3
3
  module Firecrawl
4
4
  module Models
5
- # Query format for asking a question about page content.
5
+ # Question format for asking a question about page content.
6
+ class QuestionFormat
7
+ attr_reader :question
8
+
9
+ def initialize(question:)
10
+ @question = question
11
+ end
12
+
13
+ def to_h
14
+ {
15
+ "type" => "question",
16
+ "question" => question,
17
+ }
18
+ end
19
+
20
+ def type
21
+ "question"
22
+ end
23
+ end
24
+
25
+ # Highlights format for extracting direct highlights from page content.
26
+ class HighlightsFormat
27
+ attr_reader :query
28
+
29
+ def initialize(query:)
30
+ @query = query
31
+ end
32
+
33
+ def to_h
34
+ {
35
+ "type" => "highlights",
36
+ "query" => query,
37
+ }
38
+ end
39
+
40
+ def type
41
+ "highlights"
42
+ end
43
+ end
44
+
45
+ # Deprecated query format for asking a question about page content.
6
46
  class QueryFormat
7
47
  MODE_FREEFORM = "freeform"
8
48
  MODE_DIRECT_QUOTE = "directQuote"
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Firecrawl
4
- VERSION = "1.4.0"
4
+ VERSION = "1.4.1"
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: firecrawl-sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.4.0
4
+ version: 1.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Firecrawl