Skip to content
This repository was archived by the owner on Jul 10, 2025. It is now read-only.

Commit 9740961

Browse files
author
Zhitao Li
committed
Refresh and reconcile with other discussion threads.
1 parent a87167c commit 9740961

File tree

1 file changed

+33
-27
lines changed

1 file changed

+33
-27
lines changed

rfcs/20210307-tfx-api-artifact-compat.md

Lines changed: 33 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# API & Artifact Compatibility for TFX::OSS & Libraries
22

3-
| Status | Proposed |
3+
| Status | Accepted |
44
| :------------ | :------------------------------------------------------- |
55
| **Author(s)** | Zhitao Li ([email protected]), Jiayi Zhao |
66
@@ -17,8 +17,8 @@ below) to achieve necessary API & Artifact compatibility.
1717

1818
### Goals {#goals}
1919

20-
* Clearly define a stable API surface of TFX::OSS, and lay out a
21-
structure to determine what falls into the stable public APIs.
20+
* Clearly define a stable API surface of TFX::OSS, and lay out a structure to
21+
determine what falls into the stable public APIs.
2222
* API stability: TFX::OSS (as pipeline) and all APIs from the
2323
[Key Dependency Libs](#key-dependency-libraries-in-scope) exposed through
2424
TFX::OSS should achieve desired backward compatibility (see
@@ -86,14 +86,14 @@ The following decisions are provided for easy digestion:
8686
compatible within all 1.x releases, with the exception of:
8787
1. Experimental APIs: either with `experimental` in its symbol/path, or
8888
explicitly called out in PyDoc.
89-
1. All public Python and proto APIs from tfx will be moved to a
90-
`tfx.v1` module. While accessing old symbols from unversioned
91-
API module is still possible, we recommend all public users to use
92-
the stable public API whenever possible. This also enables TFX
93-
team to release future v2 APIs if we choose do so in the long
94-
future, although there is no concrete plan for that right now.
95-
TFX API docs on TensorFlow doc sites will be updated
96-
accordingly.
89+
1. For `tfx` and `ml-pipelines-sdk` package: All public Python and
90+
proto APIs will be moved to a `tfx.v1` module. While accessing
91+
old symbols from unversioned API module is still possible, we
92+
recommend all public users to use the stable public API whenever
93+
possible. This also enables TFX team to release future v2 APIs
94+
if we choose do so in the long future, although there is no
95+
concrete plan for that right now. TFX API docs on TensorFlow doc
96+
sites will be updated accordingly.
9797
2. Internal APIs: Any other API which is not covered by our public API
9898
rules listed above are considered internal to the library, even if
9999
they do not have "internal" or underscore prefix. These APIs should
@@ -155,10 +155,10 @@ is only guaranteed to work with one version of TensorFlow.
155155
Meanwhile, there are users who need to use a different version of TensorFlow in
156156
their training code, therefore we anticipate a need to mix TFX components which
157157
link with different TensorFlow versions in the same pipeline. This is possible
158-
in a containerized deployment, because we will support configuring each component
159-
with different container images. In order to process Artifacts produced from
160-
different TensorFlow versions, we will rely on the guarantees provided by
161-
TensorFlow on SavedModel
158+
in a containerized deployment, because we will support configuring each
159+
component with different container images. In order to process Artifacts
160+
produced from different TensorFlow versions, we will rely on the guarantees
161+
provided by TensorFlow on SavedModel
162162
([source](https://www.tensorflow.org/guide/versions#compatibility_of_savedmodels_graphs_and_checkpoints)),
163163
most importantly:
164164

@@ -203,11 +203,16 @@ Therefore we propose the following for all TFX 1.x versions:
203203
to test tfx with `apache-beam` RC so such breakages should be
204204
exceedingly rare in the future.
205205

206-
For users who wants to use older versions of `apache-beam` and `tfx` together,
207-
while TFX team cannot directly support them in our released packages, we plan to
208-
refactor our build scripts so that beam dependency can be overridden by
209-
themselves, so they can build Python packages and container images in a
210-
self-service fashion.
206+
For users who wants to use older versions of `apache-beam` and `tfx` together:
207+
TFX team does not recommend such usage in general (nor directly support them),
208+
because sometimes a newer version of `apache-beam` (and many other major
209+
dependencies) offer functionality that is *required* for the TFX libraries (i.e.
210+
older versions might lead to check failures or incorrect behavior). Upon future
211+
requests, we are open to refactor, and open up, our build scripts, so that beam
212+
dependency can be overridden by users themselves, if they choose to build Python
213+
packages and container images in a self-service fashion and maintain the
214+
distribution themselves. Such users should always include the output of `pip
215+
freeze` when reporting issues, to make triaging easier.
211216

212217
#### PyArrow {#pyarrow}
213218

@@ -245,8 +250,8 @@ compatibility guarantee is the following:
245250
version of a component, we do not guarantee this will work. A warning will
246251
be generated in this case.
247252
* Resolvers and importers would only resolve Artifacts produced with same or
248-
older versions of the library, by default. A warning will be issued for
249-
any artifacts skipped due to newer versions.
253+
older versions of the library, by default. A warning will be issued for any
254+
artifacts skipped due to newer versions.
250255

251256
#### SDK (aka DSL), Official Components {#sdk-aka-dsl-official-components}
252257

@@ -342,12 +347,12 @@ to a narrow range as much as possible in these rare cases.
342347
The new orchestrator is in early stages of development and we don’t think it’ll
343348
be production-ready for 1.0 timeline, thus it will enter 1.0 as `experimental`.
344349

345-
346350
#### Intermediate Representation (IR) and Container entrypoint {#ir-entrypoint}
347351

348-
Both the intermediate representataion (IR) and container entrypoint of official
352+
Both the intermediate representation (IR) and container entrypoint of official
349353
TFX images are under active development and **excluded** from the stability /
350-
compatiblity scope of this doc.
354+
compatibility scope of this doc. We expect that changes to IR and Containers to
355+
be transparent to all users that use our higher level APIs.
351356

352357
#### Portability Layer to Other Runners (aka Orchestrators) {#portability-layer-to-other-runner-orchestrators}
353358

@@ -366,8 +371,9 @@ compatibility:
366371
The following Dag runners will remain experimental:
367372

368373
* AirflowDagRunner
369-
* Due to low utilization of the AirflowDagRunner, we want to avoid calling
370-
it stable. Support will continue to graduate it into production as utilization evolves.
374+
* Due to low usage of the AirflowDagRunner, we want to avoid calling it
375+
stable. Support will continue to graduate it into production as usage
376+
evolves.
371377

372378
The following dag runners are slated to be deprecated and therefore won’t
373379
comply:

0 commit comments

Comments
 (0)