---
title: Code base as Shadow docs
slug: test-archbee/code-base-as-shadow-docs
description: Learn how to seamlessly integrate code from a GitHub repository into Archbee without revealing the code files in the published space. Discover how to leverage the "shadowDocs" field in the .archbee.yaml file to selectively ingest code files by specifying
docTags: 
createdAt: 2023-10-25T08:02:57.000Z
---

### What is Code Base as Shadow Docs

When you sync a GitHub repo to a Space in Archbee, you have the possibility of importing your Code base into that Space as Shadow Docs. Visit [Shadow docs](<./././SPACES/AI Addon.md>)  to learn more.

This means that our [AI system](<./././SPACES/AI Addon.md>) will index all the Code you configured to be synched and will train the [Ask AI assistant](<./././SPACES/AI Addon.md>) with the provided code base.

:::hint{type="info"}
Every document added to the Shadow Docs folder will **not be visible** on your published portal, neither for your customers or for your internal users. The code provided via Shadow Docs will just be there to train your AI and be able to answer questions about your code for your users.
:::

### How can I use it?

Here are 2 of the most common use cases:

1. Sync your app code base to an Archbee Space. Publish an internal(protected, not public) portal for your tech& non-tech teams. This portal, powered by our AI, will now be able to answer questions and even suggest how to perform different improvements, integrations, optimizations, etc. based on your code-base.
2. Sync your app code base to an Archbee Space. Publish a public portal for your users. Here your users will be able to get direct answers on how to use your App, APIs, SDK, Libraries, etc

### How to configure

:::::WorkflowBlock
:::WorkflowBlockItem
First you need to configure the GitHub integration [as explained here.](././GitHub.md)

Then you need to [setup the repository](docId:8SsxlguAqtnaA2IbIp_Fu)
:::

::::WorkflowBlockItem
In the archbee.yaml file you need to configure the `shadowDocs` parameter with the path of your code base that you want to sync with Archbee.

:::CodeblockTabs
archbee.yaml

```yaml
# This will include all code files from your repo
shadowDocs: 
  - "*"
```
:::

:::CodeblockTabs
archbee.yaml

```yaml
# This will include only the index.ts code file
shadowDocs: 
  - "init/index.ts"

# To also include documentation files from docs folder
root: docs
```
:::
::::

:::WorkflowBlockItem
This is how it will look after import

![](https://api.archbee.com/api/optimize/bNBm7nPJgXjbjLyfbHNh2/mckPJUmI_MTCWHf0G-bmo_github-shadow-light.png)
:::

:::WorkflowBlockItem
Make sure you have your **AI Addon** enabled in Organisation Settings
:::
:::::

:::hint{type="success"}
**Sum-up**

- All code files sync through Shadow Docs will not be made public at any time
- The whole purpose is to provide context to our AI so it can answer technical questions and make technical suggestions to your internal or public users
:::
