Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gitbook Local 编译问题 #43

Open
THWJ opened this issue Mar 20, 2024 · 5 comments
Open

Gitbook Local 编译问题 #43

THWJ opened this issue Mar 20, 2024 · 5 comments

Comments

@THWJ
Copy link

THWJ commented Mar 20, 2024

因为官方没有提供离线的文档版本,但是我又需要在kindle上离线阅读,因此需要自己编译一个epub或pdf文档出来。

使用工具:docker:billryan/gitbook

问题:
1. 不能识别hint tag
2. 有四个md文档编译不通过

解决方案:
1. 在文档目录下新建 book.json,增加内容:

{
    "plugins": ["hints"]
}

然后执行:

sudo docker run --rm -v "$PWD:/gitbook" -p 4000:4000 billryan/gitbook gitbook install

hint标签问题解决

  1. 编译不通过的四个文档如下:
guides/application-design/prompt-engineering/conversation-application.md
guides/application-design/prompt-engineering/prompt-engineering-1/README.md
guides/application-publishing/README.md
learn-more/use-cases/create-a-midjoureny-prompt-word-robot-with-zero-code.md

暂不知道是什么原因。

Copy link

dosubot bot commented Mar 20, 2024

Based on the context provided, it seems you've already resolved the issue with the hint tag not being recognized by adding the "hints" plugin to your book.json file. That's great!

For the second issue, the four documents not compiling due to the use of <figure><image>Image description not available.</image><figcaption></figcaption></figure> method for referencing images, you're correct that this should be replaced with the ![]() method.

Here's an example of how you can replace the <figure><image>Image description not available.</image><figcaption></figcaption></figure> with the ![]() method:

# Chat App

Conversational applications use a question-and-answer model to maintain a dialogue with the user. Conversational applications support the following capabilities (please confirm that the following functions are enabled when the application is programmed):

* Variables to fill in before the dialog. Create, pin, and delete conversations.
* Conversation remarks.
* Follow-up.
* Speech to text.
* Citations and Attributions

### Variables filled in before the dialog

If you have the requirement to fill in variables when you apply the layout, you need to fill in the information according to the prompts before entering the dialog window:

![](../../.gitbook/assets/image%20(45).png)

Fill in the necessary content and click the "Start Chat" button to start chatting.

![](../../.gitbook/assets/image%20(8).png)

Move to the AI's answer, you can copy the content of the conversation, and give the answer "like" and "dislike".

![](../../.gitbook/assets/image%20(30).png)

### Conversation creation, pinning and deletion

Click the "New Conversation" button to start a new conversation. Move to a session, and the session can be "pinned" and "deleted".

![](../../.gitbook/assets/image%20(43).png)

### Conversation remarks

If the "Conversation remarks" function is enabled when the application is programmed, the AI application will automatically initiate the first sentence of the dialogue when creating a new dialogue:

![](../../.gitbook/assets/image%20(48).png)

### Follow-up

If the "Follow-up" function is enabled during the application arrangement, the system will automatically generate 3 related question suggestions after the dialogue:

![](../../.gitbook/assets/image%20(16).png)
### Speech to text

If the "Speech to Text" function is enabled during application programming, you will see the voice input icon in the input box on the web application side, click the icon to convert the voice input into text:

_Please make sure that the device environment you are using is authorized to use the microphone._

![](../../.gitbook/assets/image%20(39).png)

### Citations and Attributions

If the "Quotations and Attribution" feature is enabled during the application arrangement, the dialogue returns will automatically show the quoted knowledge document sources.

![](../../.gitbook/assets/image%20(3).png)

You can find the original document here.

Regarding your question about specific dependencies or plugins required for the compilation of these documents, there are indeed several dependencies and plugins that might not be installed or correctly configured on your system. These include Docker and Docker Compose, FFmpeg, Python 3.10.x, Node.js v18.x (LTS) and NPM version 8.x.x or Yarn, Git, OpenSSL, Celery, and Flask. You can find more detailed information about these dependencies and how to install and configure them in the installation guide.

I hope this helps! If you have any further questions or issues, please don't hesitate to ask.

Sources

About Dosu

This response is meant to be useful and save you time. It is not meant to be a precise solution, but rather a starting point for your own research.

Help me be more useful! Please leave a 👍 if this is helpful and 👎 if it is irrelevant.

If you want to continue the conversation, start your reply with @dosu-bot.

@THWJ
Copy link
Author

THWJ commented Mar 20, 2024

我好像错了,并不是figure标签的问题。我在其他能正常编译的文档中也看到了这个标签。看来需要再看看是什么标签导致的。

我没有精力去查看具体是什么原因导致的了。可能是billryan/gitbook版本太老(最新的镜像也是6年前的),某些新东西不兼容。

如果你们能直接提供编译好的epub或pdf就好了,非常感谢。

@THWJ
Copy link
Author

THWJ commented Mar 20, 2024

再补充一个错误。使用命令docker run --rm -v "$PWD:/gitbook" -p 4000:4000 billryan/gitbook gitbook pdf . 生成文件时,又出现一个错误文件:

error: error while generating page "learn-more/use-cases/build-an-notion-ai-assistant.md":

Error: unable to get local issuer certificate

@crazywoola
Copy link
Member

我们其实不太用 local 模式启动

@JayHsu5
Copy link

JayHsu5 commented May 24, 2024

\ 符号问题

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants