Markets have had an uncertain week, pulled in different directions by AI demand hopes and US government shutdown worries.