diff --git a/doc/api.md b/doc/api.md
index e06c35d65..ccbdf972d 100644
--- a/doc/api.md
+++ b/doc/api.md
@@ -198,7 +198,7 @@ Compiles a Swift module.
| swift_infos | A list of `SwiftInfo` providers from non-private dependencies of the target being compiled. The modules defined by these providers are used as dependencies of both the Swift module being compiled and the Clang module for the generated header. | none |
| swift_toolchain | The `SwiftToolchainInfo` provider of the toolchain. | none |
| target_name | The name of the target for which the code is being compiled, which is used to determine unique file paths for the outputs. | none |
-| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `Label("@rules_swift//toolchains:toolchain_type")` |
| workspace_name | The name of the workspace for which the code is being compiled, which is used to determine unique file paths for some outputs. | none |
**RETURNS**
@@ -275,7 +275,7 @@ Compiles a Swift module interface.
| swift_infos | A list of `SwiftInfo` providers from dependencies of the target being compiled. | none |
| swift_toolchain | The `SwiftToolchainInfo` provider of the toolchain. | none |
| target_name | The name of the target for which the code is being compiled, which is used to determine unique file paths for the outputs. | none |
-| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `Label("@rules_swift//toolchains:toolchain_type")` |
**RETURNS**
@@ -395,7 +395,7 @@ command line parameters file, those actions will be created here.
| module_context | The module context returned by `compile` containing information about the Swift module that was compiled. Typically, this is the first tuple element in the value returned by `compile`. | none |
| name | A string that is used to derive the name of the library or libraries linked by this function. If this is not provided or is a falsy value, the name component of the `label` argument is used. | `None` |
| swift_toolchain | The `SwiftToolchainInfo` provider of the toolchain. | none |
-| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `Label("@rules_swift//toolchains:toolchain_type")` |
| user_link_flags | A `list` of strings containing additional flags that will be passed to the linker for any binary that links with the returned linking context. | `[]` |
**RETURNS**
@@ -433,7 +433,7 @@ Extracts the symbol graph from a Swift module.
| output_dir | A directory-type `File` into which `.symbols.json` files representing the module's symbol graph will be extracted. If extraction is successful, this directory will contain a file named `${MODULE_NAME}.symbols.json`. Optionally, if the module contains extensions to types in other modules, then there will also be files named `${MODULE_NAME}@${EXTENDED_MODULE}.symbols.json`. | none |
| swift_infos | A list of `SwiftInfo` providers from dependencies of the target being compiled. This should include both propagated and non-propagated (implementation-only) dependencies. | none |
| swift_toolchain | The `SwiftToolchainInfo` provider of the toolchain. | none |
-| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `Label("@rules_swift//toolchains:toolchain_type")` |
@@ -454,7 +454,7 @@ Gets the Swift toolchain associated with the rule or aspect.
| ctx | The rule or aspect context. | none |
| exec_group | The name of the execution group that should contain the toolchain. If this is provided and the toolchain is not declared in that execution group, it will be looked up from `ctx` as a fallback instead. If this argument is `None` (the default), then the toolchain will only be looked up from `ctx.` | `None` |
| mandatory | If `False`, this function will return `None` instead of failing if no toolchain is found. Defaults to `True`. | `True` |
-| toolchain_type | The toolchain type to use. Defaults to the standard Swift toolchain type. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type to use. Defaults to the standard Swift toolchain type. | `Label("@rules_swift//toolchains:toolchain_type")` |
| attr | The name of the attribute on the calling rule or aspect that should be used to retrieve the toolchain if it is not provided by the `toolchains` argument of the rule/aspect. Note that this is only supported for legacy/migration purposes and will be removed once migration to toolchains is complete. | `"_toolchain"` |
**RETURNS**
@@ -579,7 +579,7 @@ Extracts the symbol graph from a Swift module.
| output_file | A `File` into which the synthesized interface will be written. | none |
| swift_infos | A list of `SwiftInfo` providers from dependencies of the target being compiled. This should include both propagated and non-propagated (implementation-only) dependencies. | none |
| swift_toolchain | The `SwiftToolchainInfo` provider of the toolchain. | none |
-| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type of the `swift_toolchain` which is used for the proper selection of the execution platform inside `run_toolchain_action`. | `Label("@rules_swift//toolchains:toolchain_type")` |
@@ -607,7 +607,7 @@ toolchains = use_swift_toolchain() + [other toolchains...]
| Name | Description | Default Value |
| :------------- | :------------- | :------------- |
| mandatory | Whether or not it should be an error if the toolchain cannot be resolved. Defaults to True. | `True` |
-| toolchain_type | The toolchain type to use. Defaults to the standard Swift toolchain type. | `"@build_bazel_rules_swift//toolchains:toolchain_type"` |
+| toolchain_type | The toolchain type to use. Defaults to the standard Swift toolchain type. | `Label("@rules_swift//toolchains:toolchain_type")` |
**RETURNS**
diff --git a/swift/internal/toolchain_utils.bzl b/swift/internal/toolchain_utils.bzl
index ba4a97b85..7aa3f3378 100644
--- a/swift/internal/toolchain_utils.bzl
+++ b/swift/internal/toolchain_utils.bzl
@@ -14,7 +14,7 @@
"""Helpers used to depend on and access the Swift toolchain."""
-SWIFT_TOOLCHAIN_TYPE = "@build_bazel_rules_swift//toolchains:toolchain_type"
+SWIFT_TOOLCHAIN_TYPE = Label("//toolchains:toolchain_type")
def get_swift_toolchain(
ctx,