File tree Expand file tree Collapse file tree 1 file changed +0
-38
lines changed Expand file tree Collapse file tree 1 file changed +0
-38
lines changed Original file line number Diff line number Diff line change @@ -75,44 +75,6 @@ output = replicate.run(...)
7575
7676The ` api_token ` parameter is still accepted for backward compatibility, but ` bearer_token ` is preferred.
7777
78- ## Running models
79-
80- The basic ` run() ` method works similarly, but the ` wait ` parameter handling has changed.
81-
82- ### Before (v1)
83-
84- ``` python
85- # Wait up to 60 seconds (default)
86- output = replicate.run(
87- " black-forest-labs/flux-schnell" ,
88- input = {" prompt" : " astronaut riding a rocket" }
89- )
90-
91- # Custom timeout
92- output = replicate.run(... , wait = 30 )
93-
94- # Don't wait
95- output = replicate.run(... , wait = False )
96- ```
97-
98- ### After (v2)
99-
100- ``` python
101- # Wait up to 60 seconds (default)
102- output = replicate.run(
103- " black-forest-labs/flux-schnell" ,
104- input = {" prompt" : " astronaut riding a rocket" }
105- )
106-
107- # Custom timeout
108- output = replicate.run(... , wait = 30 )
109-
110- # Don't wait
111- output = replicate.run(... , wait = False )
112- ```
113-
114- The interface is the same, but v2 uses HTTP ` Prefer ` headers internally for better standards compliance.
115-
11678## Streaming output
11779
11880Streaming works similarly, but prediction objects no longer have a ` stream() ` method.
You can’t perform that action at this time.
0 commit comments