Add fuzzy and text-classification light model #1
					 2 changed files with 10 additions and 2 deletions
				
			
		Add mpd ip as argument
				commit
				
					
					
						86500c3164
					
				
			
		
							
								
								
									
										10
									
								
								main.py
									
										
									
									
									
								
							
							
						
						
									
										10
									
								
								main.py
									
										
									
									
									
								
							|  | @ -24,6 +24,7 @@ parser = argparse.ArgumentParser( | ||||||
| parser.add_argument('mode') | parser.add_argument('mode') | ||||||
| parser.add_argument('-i', '--ip', required=False) | parser.add_argument('-i', '--ip', required=False) | ||||||
| parser.add_argument('-p', '--port', required=False, type=int) | parser.add_argument('-p', '--port', required=False, type=int) | ||||||
|  | parser.add_argument('-m', '--mpd', required=False) | ||||||
| 
 | 
 | ||||||
| args = parser.parse_args() | args = parser.parse_args() | ||||||
| 
 | 
 | ||||||
|  | @ -47,7 +48,14 @@ logging.info("Loading ratatouilles modules") | ||||||
| 
 | 
 | ||||||
| walle = Hass(config.hass_url, config.hass_token) | walle = Hass(config.hass_url, config.hass_token) | ||||||
| yoda = None  # Rhasspy(config.rhasspy_url) | yoda = None  # Rhasspy(config.rhasspy_url) | ||||||
| mopidy = Mpd('10.10.10.8') | 
 | ||||||
|  | mopidy = None | ||||||
|  | 
 | ||||||
|  | if args.mpd is not None: | ||||||
|  |     mopidy = Mpd(args.mpd) | ||||||
|  | else: | ||||||
|  |     logging.warning('Starting without MPD connection') | ||||||
|  | 
 | ||||||
| ratatouille = Ratatouille(yoda, walle, mopidy, None) | ratatouille = Ratatouille(yoda, walle, mopidy, None) | ||||||
| # alexa = AlexaIntent() # we are not doing any request to the evil amazon but we are using one of its dataset | # alexa = AlexaIntent() # we are not doing any request to the evil amazon but we are using one of its dataset | ||||||
| bert = BertIntent() | bert = BertIntent() | ||||||
|  |  | ||||||
|  | @ -23,7 +23,7 @@ class Ratatouille(): | ||||||
|         # schedule.every().day.at(config.hibernate_time).do(self.hibernate) |         # schedule.every().day.at(config.hibernate_time).do(self.hibernate) | ||||||
|         # schedule.every().day.at(config.wakeup_time).do(self.clear_hibernate) |         # schedule.every().day.at(config.wakeup_time).do(self.clear_hibernate) | ||||||
|         # yoda.say('Ratatouille a bien démmaré') |         # yoda.say('Ratatouille a bien démmaré') | ||||||
|         logging.info('loaded') |         # logging.info('loaded') | ||||||
| 
 | 
 | ||||||
|     def parse_rhasspy_command(self, payload): |     def parse_rhasspy_command(self, payload): | ||||||
|         command = payload['intent']['intentName'] |         command = payload['intent']['intentName'] | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue