Skip to content

Commit

Permalink
docs: update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
hanxiao authored Jan 3, 2021
1 parent 2e7786c commit 3178fef
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -234,10 +234,11 @@ To add logic to the Flow, use the `uses` parameter to attach a Pod with an [Exec

```python
f = (Flow().add(uses='MyBertEncoder') # class name of a Jina Executor
.add(uses='jinahub/pretrained-cnn:latest') # Dockerized Jina Pod
.add(uses='docker://jinahub/pretrained-cnn:latest') # the container name
.add(uses='myencoder.yaml') # YAML serialization of a Jina Executor
.add(uses='!WaveletTransformer | {freq: 20}') # inline YAML config
.add(uses='_pass')) # built-in shortcut executor
.add(uses={'__cls': 'MyBertEncoder', 'with': {'param': 1.23}}) # dict config object with __cls keyword
```

The power of Jina lies in its decentralized architecture: each `add` creates a new Pod, and these Pods can be run as a local thread/process, a remote process, inside a Docker container, or even inside a remote Docker container.
Expand Down

0 comments on commit 3178fef

Please sign in to comment.