如何将我在IBM Bluemix上的javascript Web应用程序与我在Manifest.yml中创建的任何Watson API服务绑定?

时间:2021-05-11 15:10:14

How to bind my javascript web app on IBM Bluemix with any Watson API service created by me in Manifest.yml?

如何将我在IBM Bluemix上的javascript Web应用程序与我在Manifest.yml中创建的任何Watson API服务绑定?

We followed the following tutorials to make tthis Watson Car Conversation - Simple app demo to work on my local computer and Bluemix hosting. https://github.com/eGlobeBizCom/conversation-simple This Q is also posted at the comments section of this video https://www.youtube.com/watch?v=9M86BfL9KX0

我们按照以下教程制作了Watson Car Conversation - 简单的应用程序演示,可以在我的本地计算机和Bluemix主机上运行。 https://github.com/eGlobeBizCom/conversation-simple此Q也发布在此视频的评论部分https://www.youtube.com/watch?v=9M86BfL9KX0

*This demo app can work on my local computer; *But deploying the above app to Bluemix, not successful.

*此演示应用程序可以在我的本地计算机上运行; *但是将上述应用程序部署到Bluemix,却没有成功。

The problem: After type "cf push" on Gitbash, the results: Most steps are deployed, this step gives me the failed message:

Failed. Could not find service conversation - free to bind to WatsonCarApp (This is the app name in the manifest.yml, I gave this app name)

Many searches on the web have no helpful info. IBM Bluemix hosting and Watson API Service teams really need to improve tutorial and tech support. Any suggestions will be appreciated.

网上的许多搜索都没有有用的信息。 IBM Bluemix托管和Watson API服务团队确实需要改进教程和技术支持。任何建议将不胜感激。

2 个解决方案

#1


1  

Your manifest.yml file expects a Watson Conversation service named conversation-free, so before you push your application you need to run the following command to create this service:

您的manifest.yml文件需要一个名为无会话的Watson Conversation服务,因此在推送应用程序之前,您需要运行以下命令来创建此服务:

$ cf create-service conversation free conversation-free

$ cf创建服务对话免费对话免费

after that you can run cf push to deploy your application.

之后,您可以运行cf push来部署您的应用程序。

These should fix the error you are seeing about not finding the conversation-free service.

这些应该可以解决您没有找到无会话服务的错误。

If you created your Watson conversation service via UI, please use a manifest.yml file similar to below to deploy your application:

如果您通过UI创建了Watson会话服务,请使用类似于以下的manifest.yml文件来部署您的应用程序:

applications:
- name: WatsonCarApp
  services:
  - Conversation-4i
  command: npm start
  path: .
  instances: 1
  memory: 512MB

PS: manifest.yml assumes your application name is WatsonCarApp and your service name is Conversation-4i

PS:manifest.yml假设您的应用程序名称是WatsonCarApp,您的服务名称是Conversation-4i

#2


0  

Now the above demo app works in my account in Bluemix. The people who are new to Bluemix or Watson app, need to read the above comments carefully in order to get the app run on Bluemix. Thanks for the timely replies from Alex.

现在,上面的演示应用程序在我的Bluemix帐户中运行。不熟悉Bluemix或Watson app的人需要仔细阅读上述评论才能在Bluemix上运行应用程序。感谢Alex的及时回复。

Hope someone who understands Watson conversation API can reply my following Q related to this: IBM Watson Car-Dashboard demo gave wrong replies to some of my Q in my copy of this demo

希望有人了解Watson会话API可以回复我的以下与此相关的问题:IBM Watson Car-Dashboard演示在我的演示副本中对我的部分Q进行了错误的回复

#1


1  

Your manifest.yml file expects a Watson Conversation service named conversation-free, so before you push your application you need to run the following command to create this service:

您的manifest.yml文件需要一个名为无会话的Watson Conversation服务,因此在推送应用程序之前,您需要运行以下命令来创建此服务:

$ cf create-service conversation free conversation-free

$ cf创建服务对话免费对话免费

after that you can run cf push to deploy your application.

之后,您可以运行cf push来部署您的应用程序。

These should fix the error you are seeing about not finding the conversation-free service.

这些应该可以解决您没有找到无会话服务的错误。

If you created your Watson conversation service via UI, please use a manifest.yml file similar to below to deploy your application:

如果您通过UI创建了Watson会话服务,请使用类似于以下的manifest.yml文件来部署您的应用程序:

applications:
- name: WatsonCarApp
  services:
  - Conversation-4i
  command: npm start
  path: .
  instances: 1
  memory: 512MB

PS: manifest.yml assumes your application name is WatsonCarApp and your service name is Conversation-4i

PS:manifest.yml假设您的应用程序名称是WatsonCarApp,您的服务名称是Conversation-4i

#2


0  

Now the above demo app works in my account in Bluemix. The people who are new to Bluemix or Watson app, need to read the above comments carefully in order to get the app run on Bluemix. Thanks for the timely replies from Alex.

现在,上面的演示应用程序在我的Bluemix帐户中运行。不熟悉Bluemix或Watson app的人需要仔细阅读上述评论才能在Bluemix上运行应用程序。感谢Alex的及时回复。

Hope someone who understands Watson conversation API can reply my following Q related to this: IBM Watson Car-Dashboard demo gave wrong replies to some of my Q in my copy of this demo

希望有人了解Watson会话API可以回复我的以下与此相关的问题:IBM Watson Car-Dashboard演示在我的演示副本中对我的部分Q进行了错误的回复